workflow-cps-plugin icon indicating copy to clipboard operation
workflow-cps-plugin copied to clipboard

[JENKINS-42971] CpsScmFlowDefinition sends build to SCMFileSystem in …

Open MartinKosicky opened this issue 2 years ago • 17 comments

I added in CpsScmFlowDefinition (create) to send to lightweight checkout the build value into SCMFileSystem.of which is changed in https://github.com/jenkinsci/scm-api-plugin/pull/160. The goal is to be able to expand branch value by build params if branch name contains for example ${BRANCH}

MartinKosicky avatar Aug 02 '22 11:08 MartinKosicky

Ought to include an integration test picking up jenkinsci/git-plugin#1305 and demonstrating effectiveness in solving the stated bug.

Im planning to add integration test here and unit test in Git plugin

MartinKosicky avatar Aug 02 '22 18:08 MartinKosicky

Ought to include an integration test picking up jenkinsci/git-plugin#1305 and demonstrating effectiveness in solving the stated bug.

Done

MartinKosicky avatar Aug 04 '22 09:08 MartinKosicky

hmm, are these check fails related to this PR ?

MartinKosicky avatar Aug 04 '22 13:08 MartinKosicky

are these check fails related to this PR ?

From a quick glance, looks like infrastructure problems with Windows agents; retriggered build.

jglick avatar Aug 04 '22 14:08 jglick

are these check fails related to this PR ?

From a quick glance, looks like infrastructure problems with Windows agents; retriggered build.

Now there is a bunch of No test report files were found. Configuration error? and Caused: java.io.IOException: Remote call on JNLP4-connect connection from 20.102.0.182/20.102.0.182:11009 failed

:(

MartinKosicky avatar Aug 05 '22 05:08 MartinKosicky

https://ci.jenkins.io/job/Plugins/job/workflow-cps-plugin/job/PR-577/10/execution/node/53/ is https://issues.jenkins.io/browse/JENKINS-69229

jglick avatar Aug 05 '22 12:08 jglick

OK, that much seems to be fixed, sorry for the interruption. @dduportal FYI

jglick avatar Aug 05 '22 12:08 jglick

Ok this is testCase I was working on but not that test, hmm. Locally they were all sucesful. I will assume that I broke something?

MartinKosicky avatar Aug 05 '22 13:08 MartinKosicky

Edit docs: https://github.com/jenkinsci/workflow-cps-plugin/pull/329#discussion_r449219600

jglick avatar Aug 05 '22 14:08 jglick

hmm, ill try to bump the versions?

MartinKosicky avatar Aug 11 '22 08:08 MartinKosicky

@jglick do you have any suggestion if I should bump the versions in git plugin? or what should we do here ?

MartinKosicky avatar Aug 11 '22 10:08 MartinKosicky

When I import the incremental build of git plugin to my Idea, I see different versions than those that were specified in the incremental .pom file. Also the test seems to look at the pom definitions? Or I dont know where it knows the versions, but I see that maven loaded a different version than was generated in the .pom

MartinKosicky avatar Aug 11 '22 13:08 MartinKosicky

When I import the incremental build of git plugin to my Idea, I see different versions

You may need to configure your IDE to honor https://github.com/jenkinsci/workflow-cps-plugin/blob/9101f1bd0b7e6f8873d96bed8e16a7505e2186b3/.mvn/maven.config#L1 NetBeans does this automatically; I have no idea about IDEA (sorry for the pun). If in doubt, command-line mvn is authoritative.

Failed to load: Git plugin (git 4.12.0-rc4821.0fa_d6b_a_a_0928)
 - Update required: Jenkins Mailer Plugin (mailer 414.vcc4c33714601) to be updated to 435.v79ef3972b_5c7 or higher
 - Update required: Token Macro Plugin (token-macro 293.v283932a_0a_b_49) to be updated to 308.v4f2b_ed62b_b_16 or higher
 - Update required: Structs Plugin (structs 318.va_f3ccb_729b_71) to be updated to 324.va_f5d6774f3a_d or higher

possibly just means that this should subsume #574.

jglick avatar Aug 11 '22 14:08 jglick

Yes I am taking the incrementals, i saw this behaviour also in mvn dependency tree to confirm.

MartinKosicky avatar Aug 11 '22 14:08 MartinKosicky

So what exactly are you seeing then?

jglick avatar Aug 11 '22 14:08 jglick

So what exactly are you seeing then?

I tried to bump the BOM that you mentioned in that PR, and it helped, I guess that was the problem

MartinKosicky avatar Aug 11 '22 18:08 MartinKosicky

(draft until all deps are released)

jglick avatar Aug 11 '22 20:08 jglick

hmm the build seemed to completely change , now i have to figure out how to build this thing in idea :(

ok i seemed to broke the history by some dump rebase , eh

MartinKosicky avatar Dec 16 '22 19:12 MartinKosicky

I think it shouls be ok now

MartinKosicky avatar Dec 17 '22 07:12 MartinKosicky

@MarkEWaite hello, will you have time so we can finalize these 3 PRs. This one is the last and I think you also tested this already when we were working with the git-scm

MartinKosicky avatar Dec 20 '22 09:12 MartinKosicky

I've added it to the plugins.txt file that I'm using for my testing of git plugin 5.0.0 and git client plugin 4.0.0. I'll include the details of JENKINS-42971 in my testing.

MarkEWaite avatar Dec 20 '22 20:12 MarkEWaite

I've confirmed that the incremental release of this pull request resolves JENKINS-42971. I tested with the git plugin 5.0.0 pre-release and the git client plugin 4.0.0 pre-release.

MarkEWaite avatar Dec 20 '22 23:12 MarkEWaite

Thanks! Approved

Thank you :). Hmm just a quick question, how does the merging process work here? Who will merge this or we need more approvals?

MartinKosicky avatar Dec 21 '22 10:12 MartinKosicky

Thanks! Approved

Thank you :). Hmm just a quick question, how does the merging process work here? Who will merge this or we need more approvals?

One of the maintainers needs to merge it. Since two of them have approved the pull request, I believe it is ready for merge. Once it is merged, the continuous delivery process will release a new version of the plugin.

MarkEWaite avatar Dec 21 '22 13:12 MarkEWaite

Note that in this project, being ready for merge is no guarantee that a pull request will be merged in a timely fashion. I routinely file PRs that are approved by maintainers with the green checkmark yet remain unmerged (and therefore unreleased) for an extended period of time.

basil avatar Dec 21 '22 17:12 basil

@dwnusbaum was most recently reviewing seriously

No, my recent review was just to try to help resolve https://github.com/jenkinsci/workflow-cps-plugin/pull/577#issuecomment-1355502611 and a bad merge related to https://github.com/jenkinsci/workflow-cps-plugin/pull/612, which is something I worked on. I have not looked at this PR beyond that.

dwnusbaum avatar Dec 21 '22 17:12 dwnusbaum

I found no issues related to this change in my testing of git plugin 5.0.0 and git client plugin 4.0.0. I would like to see it merged and released. Thanks for your patience @MartinKosicky !

MarkEWaite avatar Dec 30 '22 15:12 MarkEWaite

Thank you :)

MartinKosicky avatar Jan 04 '23 07:01 MartinKosicky

Thank you for driving this forward and for your patience.

jglick avatar Jan 04 '23 13:01 jglick