Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-18762

Build number environment variable is not propagated when run inside a conditional build step

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      When artifacts are copied through a conditional build setup, the build number environment variable (e.g. COPYARTIFACT_BUILD_NUMBER_...) does not get propagated (or is not visible) to the remaining build steps.

        Attachments

          Issue Links

            Activity

            Show
            ikedam ikedam added a comment - https://github.com/jenkinsci/copyartifact-plugin/pull/47
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/test/java/hudson/plugins/copyartifact/CopyArtifactTest.java
            src/test/java/hudson/plugins/copyartifact/testutils/WrapperBuilder.java
            http://jenkins-ci.org/commit/copyartifact-plugin/6ccfac85e2f41a1152688408889849fb6c38f6b3
            Log:
            JENKINS-16028 JENKINS-18762 Added tests to reproduce JENKINS-16028 (environment variables are not set in maven prebuild), JENKINS-18762 (environment variables are not set when wrapped in another builder).

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/test/java/hudson/plugins/copyartifact/CopyArtifactTest.java src/test/java/hudson/plugins/copyartifact/testutils/WrapperBuilder.java http://jenkins-ci.org/commit/copyartifact-plugin/6ccfac85e2f41a1152688408889849fb6c38f6b3 Log: JENKINS-16028 JENKINS-18762 Added tests to reproduce JENKINS-16028 (environment variables are not set in maven prebuild), JENKINS-18762 (environment variables are not set when wrapped in another builder).
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/main/java/hudson/plugins/copyartifact/CopyArtifact.java
            http://jenkins-ci.org/commit/copyartifact-plugin/581c57e7068bca29cdbfcdb15419ac7d8e3b1fa4
            Log:
            [FIXED JENKINS-16028] [FIXED JENKINS-18762] Adds EnvAction to hold COPYARTIFACT_BUILD_NUMBER_XXX when it's needed. It was added when a build starts and the build has copyartifact, which doesn't work for maven-project and copyartifacts wrapped in other builders.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/java/hudson/plugins/copyartifact/CopyArtifact.java http://jenkins-ci.org/commit/copyartifact-plugin/581c57e7068bca29cdbfcdb15419ac7d8e3b1fa4 Log: [FIXED JENKINS-16028] [FIXED JENKINS-18762] Adds EnvAction to hold COPYARTIFACT_BUILD_NUMBER_XXX when it's needed. It was added when a build starts and the build has copyartifact, which doesn't work for maven-project and copyartifacts wrapped in other builders.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/main/java/hudson/plugins/copyartifact/CopyArtifact.java
            src/test/java/hudson/plugins/copyartifact/CopyArtifactTest.java
            src/test/java/hudson/plugins/copyartifact/testutils/WrapperBuilder.java
            http://jenkins-ci.org/commit/copyartifact-plugin/c11b82688863105971e00cc27ad0501af436d903
            Log:
            Merge pull request #47 from ikedam/feature/JENKINS-16028_EnvActionWhenNeeded

            JENKINS-16028 JENKINS-18762 Adds EnvAction when it's needed

            Compare: https://github.com/jenkinsci/copyartifact-plugin/compare/22eb37c9763a...c11b82688863

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/java/hudson/plugins/copyartifact/CopyArtifact.java src/test/java/hudson/plugins/copyartifact/CopyArtifactTest.java src/test/java/hudson/plugins/copyartifact/testutils/WrapperBuilder.java http://jenkins-ci.org/commit/copyartifact-plugin/c11b82688863105971e00cc27ad0501af436d903 Log: Merge pull request #47 from ikedam/feature/ JENKINS-16028 _EnvActionWhenNeeded JENKINS-16028 JENKINS-18762 Adds EnvAction when it's needed Compare: https://github.com/jenkinsci/copyartifact-plugin/compare/22eb37c9763a...c11b82688863
            Hide
            ikedam ikedam added a comment -

            Fixed in copyartifact 1.32.

            Show
            ikedam ikedam added a comment - Fixed in copyartifact 1.32.

              People

              • Assignee:
                ikedam ikedam
                Reporter:
                darnaut Davi Arnaut
              • Votes:
                2 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: