More in general the parameters of the "previous" run are used.
We have seen this when playing around with some kind of "dynamic value" for a parameter. We have a single (declarative) Pipeline which has a parameter to enable a DEBUG build. During the continuous CI builds, DEBUG mode is enabled, i.e. the `BUILD_DEBUG` parameter to false. On a nightly build, we set the `BUILD_DEBUG` parameter to false.
the "nightly build" correctly sets the parameter to false
and the "daily builds" correctly set it to true.
but the parameter value is only applied in the next build !
The "nightly build" still uses `DEBUG_BUILD=true`
While the first "daily build" uses `DEBUG_BUILD=false`
I.e. When creating a new branch this applies too: (FYI: We use the Multibranch pipeline plugin on subversion repositories) The first build has no "previous build"and thus "no parameters" Which exactly explains what is seen on the first build of a (declarative) pipeline.
In my opinion the `parameters` must be definedandapplied on the current build.
I hope this information is of any use for you!
We will look for a workaround for now, but it would be great to see this fixed. Thank you in advance for the effort!
This message was sent by Atlassian JIRA (v7.3.0#73011-sha1:3c73d0e)
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.