[JIRA] (JENKINS-45771) Disable shallow clone when we know a merge will take place

2019-07-12 Thread mark.earl.wa...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mark Waite updated  JENKINS-45771  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-45771  
 
 
  Disable shallow clone when we know a merge will take place   
 

  
 
 
 
 

 
Change By: 
 Mark Waite  
 
 
Status: 
 Reopened Open  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 

   





-- 
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 jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.183978.1500974294000.8867.1562947020913%40Atlassian.JIRA.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-45771) Disable shallow clone when we know a merge will take place

2018-10-31 Thread stephen.alan.conno...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Stephen Connolly assigned an issue to Unassigned  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Removing myself as assignee. My current work assignments do not provide sufficient bandwidth to review these issues and in the majority of cases I am only assigned by virtue of being the default assignee. For the credentials-api and scm-api related plugins I have permission to allocate time reviewing changes to these APIs themselves to ensure these APIs remain cohesive, but that can be handled through PR reviews rather than assigning issues in JIRA  
 

  
 
 
 
 

 
 Jenkins /  JENKINS-45771  
 
 
  Disable shallow clone when we know a merge will take place   
 

  
 
 
 
 

 
Change By: 
 Stephen Connolly  
 
 
Assignee: 
 Stephen Connolly  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 

   





-- 
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 jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-45771) Disable shallow clone when we know a merge will take place

2018-04-17 Thread sherman.y...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Shiqi Yang edited a comment on  JENKINS-45771  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Disable shallow clone when we know a merge will take place   
 

  
 
 
 
 

 
 I found a case where this bug still applies in parallel stages, reopen this one since I think it is the same issue but please let me know if it is not and I can open another oneenvironment:jenkins 2.89.3github-branch-source-plugin 2.32.2I have a multibranch project setup with `discover the pull requests from origin``merge pull request with target`fetch all tagsshallow clone I also have Basic Branch Build Strategies Plugin installed to stop the build storm when we scan repo but I don't think it is relatedmy pipeline file has 2 parallel stages and one of the stages has its own node {} section to specify the builder label and workspace path.it looks like this (this is almost the same example of https://jenkins.io/blog/2017/09/25/declarative-1, only difference here is that I have customWorkspace specified on the nodes to reuse the local code repo in the hope to save some time on git clone, our git repo is huge):{code:java}pipeline { agent nonestages {stage('Run Tests') {parallel {stage('Test 1') {agent { label "windows" customWorkspace "${env.HOME}/TEST1"}steps { bat "run-tests.bat"}post { always { junit "**/TEST-*.xml" }}}stage('Test On Linux') {agent { label "linux" customWorkspace "${env.HOME}/TEST2"}steps { sh "run-tests.sh"}post { always { junit "**/TEST-*.xml" }}}}}}}{code}the error I am seeing is that when the pipeline enters the parallel stages, especially after the workspace switch, it will fail to merge if the PR is couple of commits behind master because the head of master is checked out without git history. ( I logged in to the builder after the failure and manually verified that in the workspace)it seems that removing  two ways to resolve this for now:1 remove  the  the  customWorkspace  this is not going to work well for us because the lack of self clean on the branches of multibranch (without customworkspace different branch runs  will  help resolve  not share workspace in current design of multibranch pipeline)2. add 'wipe out workspace and clone again in advanced' settings. (  this  will increase our build time tremendously because our github repo is big, and unnecessary)   {code:java}> /usr/local/bin/git rev-parse --is-inside-work-tree # timeout=10Fetching changes from the remote Git repository > /usr/local/bin/git config remote.origin.url !INFO_EXTRACTED! # timeout=10Fetching upstream changes from !INFO_EXTRACTED! > /usr/local/bin/git --version # timeout=10using GIT_ASKPASS to set credentials JENKINS_GH > /usr/local/bin/git fetch --tags --progress !INFO_EXTRACTED! +refs/pull/!INFO_EXTRACTED!/head:refs/remotes/origin/PR-!INFO_EXTRACTED! +refs/heads/master:refs/remotes/origin/master # timeout=60Merging remotes/origin/master commit !INFO_EXTRACTED! into PR head commit !INFO_EXTRACTED! > /usr/local/bin/git config core.sparsecheckout # timeout=10 > /usr/local/bin/git checkout -f !INFO_EXTRACTED! > /usr/local/bin/git merge !INFO_EXTRACTED! # timeout=10 > /usr/local/bin/git config core.sparsecheckout # 

[JIRA] (JENKINS-45771) Disable shallow clone when we know a merge will take place

2018-04-17 Thread sherman.y...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Shiqi Yang edited a comment on  JENKINS-45771  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Disable shallow clone when we know a merge will take place   
 

  
 
 
 
 

 
 I found a case where this bug still applies in parallel stages, reopen this one since I think it is the same issue but please let me know if it is not and I can open another oneenvironment:jenkins 2.89.3github-branch-source-plugin 2.32.2I have a multibranch project setup with `discover the pull requests from origin``merge pull request with target`fetch all tagsshallow clone I also have Basic Branch Build Strategies Plugin installed to stop the build storm when we scan repo but I don't think it is relatedmy pipeline file has 2 parallel stages and one of the stages has its own node {} section to specify the builder label and workspace path.it looks like this (this is almost the same example of https://jenkins.io/blog/2017/09/25/declarative-1, only difference here is that I have customWorkspace specified on the nodes to reuse the local code repo in the hope to save some time on git clone, our git repo is huge):{code:java}pipeline { agent nonestages {stage('Run Tests') {parallel {stage('Test 1') {agent { label "windows" customWorkspace "${env.HOME}/TEST1"}steps { bat "run-tests.bat"}post { always { junit "**/TEST-*.xml" }}}stage('Test On Linux') {agent { label "linux" customWorkspace "${env.HOME}/TEST2"}steps { sh "run-tests.sh"}post { always { junit "**/TEST-*.xml" }}}}}}}{code}the error I am seeing is that when the pipeline enters the parallel stages, especially after the workspace switch, it will fail to merge if the PR is couple of commits behind master because the head of master is checked out without git history. ( I logged in to the builder after the failure and manually verified that in the workspace)it seems that removing the customWorkspace will help resolve this{code:java}> /usr/local/bin/git rev-parse --is-inside-work-tree # timeout=10Fetching changes from the remote Git repository > /usr/local/bin/git config remote.origin.url !INFO_EXTRACTED! # timeout=10Fetching upstream changes from !INFO_EXTRACTED! > /usr/local/bin/git --version # timeout=10using GIT_ASKPASS to set credentials JENKINS_GH > /usr/local/bin/git fetch --tags --progress !INFO_EXTRACTED! +refs/pull/!INFO_EXTRACTED!/head:refs/remotes/origin/PR-!INFO_EXTRACTED! +refs/heads/master:refs/remotes/origin/master # timeout=60Merging remotes/origin/master commit !INFO_EXTRACTED! into PR head commit !INFO_EXTRACTED! > /usr/local/bin/git config core.sparsecheckout # timeout=10 > /usr/local/bin/git checkout -f !INFO_EXTRACTED! > /usr/local/bin/git merge !INFO_EXTRACTED! # timeout=10 > /usr/local/bin/git config core.sparsecheckout # timeout=10 > /usr/local/bin/git checkout -f !INFO_EXTRACTED!Command "/usr/local/bin/git merge !INFO_EXTRACTED!" returned status code 128:stdout: stderr: fatal: refusing to merge unrelated histories{code}FYI I remove the sensitive date from the output and replaced with  `  !INFO_EXTRACTED! `  
 


[JIRA] (JENKINS-45771) Disable shallow clone when we know a merge will take place

2018-04-17 Thread sherman.y...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Shiqi Yang edited a comment on  JENKINS-45771  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Disable shallow clone when we know a merge will take place   
 

  
 
 
 
 

 
 I found a case where this bug still applies in parallel stages, reopen this one since I think it is the same issue but please let me know if it is not and I can open another oneenvironment:jenkins 2.89.3github-branch-source-plugin 2.32.2I have a multibranch project setup with `discover the pull requests from origin``merge pull request with target`fetch all tagsshallow clone I also have Basic Branch Build Strategies Plugin installed to stop the build storm when we scan repo but I don't think it is relatedmy pipeline file has 2 parallel stages and one of the stages has its own node {} section to specify the builder label and workspace path.it looks like this (this is almost the same example of https://jenkins.io/blog/2017/09/25/declarative-1, only difference here is that I have customWorkspace specified on the nodes to reuse the local code repo in the hope to save some time on git clone, our git repo is huge):{code:java}pipeline { agent nonestages {stage('Run Tests') {parallel {stage('Test 1') {agent { label "windows" customWorkspace "${env.HOME}/TEST1"}steps { bat "run-tests.bat"}post { always { junit "**/TEST-*.xml" }}}stage('Test On Linux') {agent { label "linux" customWorkspace "${env.HOME}/TEST2"}steps { sh "run-tests.sh"}post { always { junit "**/TEST-*.xml" }}}}}}}{code}the error I am seeing is that when the pipeline enters the parallel stages, especially after the workspace switch, it will fail to merge if the PR is couple of commits behind master because the head of master is checked out without git history. ( I logged in to the builder after the failure and manually verified that in the workspace)it seems that removing the customWorkspace will help resolve this{code:java}> /usr/local/bin/git rev-parse --is-inside-work-tree # timeout=10Fetching changes from the remote Git repository > /usr/local/bin/git config remote.origin.url !INFO_EXTRACTED! # timeout=10Fetching upstream changes from !INFO_EXTRACTED! > /usr/local/bin/git --version # timeout=10using GIT_ASKPASS to set credentials JENKINS_GH > /usr/local/bin/git fetch --tags --progress !INFO_EXTRACTED! +refs/pull/!INFO_EXTRACTED!/head:refs/remotes/origin/PR-!INFO_EXTRACTED! +refs/heads/master:refs/remotes/origin/master # timeout=60Merging remotes/origin/master commit !INFO_EXTRACTED! into PR head commit !INFO_EXTRACTED! > /usr/local/bin/git config core.sparsecheckout # timeout=10 > /usr/local/bin/git checkout -f !INFO_EXTRACTED! > /usr/local/bin/git merge !INFO_EXTRACTED! # timeout=10 > /usr/local/bin/git config core.sparsecheckout # timeout=10 > /usr/local/bin/git checkout -f !INFO_EXTRACTED!Command "/usr/local/bin/git merge !INFO_EXTRACTED!" returned status code 128:stdout: stderr: fatal: refusing to merge unrelated histories{code}FYI I remove the sensitive date from the output and replaced with  `  (' !INFO_EXTRACTED !` ')  
 

  

[JIRA] (JENKINS-45771) Disable shallow clone when we know a merge will take place

2018-04-17 Thread sherman.y...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Shiqi Yang edited a comment on  JENKINS-45771  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Disable shallow clone when we know a merge will take place   
 

  
 
 
 
 

 
 I found a case where this bug still applies in parallel stages, reopen this one since I think it is the same issue but please let me know if it is not and I can open another oneenvironment:jenkins 2.89.3github-branch-source-plugin 2.32.2I have a multibranch project setup with `discover the pull requests from origin``merge pull request with target`fetch all tagsshallow clone I also have Basic Branch Build Strategies Plugin installed to stop the build storm when we scan repo but I don't think it is relatedmy pipeline file has 2 parallel stages and one of the stages has its own node {} section to specify the builder label and workspace path.it looks like this (this is almost the same example of https://jenkins.io/blog/2017/09/25/declarative-1, only difference here is that I have customWorkspace specified on the nodes to reuse the local code repo in the hope to save some time on git clone, our git repo is huge):{code:java}pipeline { agent nonestages {stage('Run Tests') {parallel {stage('Test 1') {agent { label "windows" customWorkspace "${env.HOME}/TEST1"}steps { bat "run-tests.bat"}post { always { junit "**/TEST-*.xml" }}}stage('Test On Linux') {agent { label "linux" customWorkspace "${env.HOME}/TEST2"}steps { sh "run-tests.sh"}post { always { junit "**/TEST-*.xml" }}}}}}}{code}the error I am seeing is that when the pipeline enters the parallel stages, especially after the workspace switch, it will fail to merge if the PR is couple of commits behind master because the head of master is checked out without git history. ( I logged in to the builder after the failure and manually verified that in the workspace)it seems that removing the customWorkspace will help resolve this{code:java}> /usr/local/bin/git rev-parse --is-inside-work-tree # timeout=10Fetching changes from the remote Git repository > /usr/local/bin/git config remote.origin.url !INFO_EXTRACTED! # timeout=10Fetching upstream changes from !INFO_EXTRACTED! > /usr/local/bin/git --version # timeout=10using GIT_ASKPASS to set credentials JENKINS_GH > /usr/local/bin/git fetch --tags --progress !INFO_EXTRACTED! +refs/pull/!INFO_EXTRACTED!/head:refs/remotes/origin/PR-!INFO_EXTRACTED! +refs/heads/master:refs/remotes/origin/master # timeout=60Merging remotes/origin/master commit !INFO_EXTRACTED! into PR head commit !INFO_EXTRACTED! > /usr/local/bin/git config core.sparsecheckout # timeout=10 > /usr/local/bin/git checkout -f !INFO_EXTRACTED! > /usr/local/bin/git merge !INFO_EXTRACTED! # timeout=10 > /usr/local/bin/git config core.sparsecheckout # timeout=10 > /usr/local/bin/git checkout -f !INFO_EXTRACTED!Command "/usr/local/bin/git merge !INFO_EXTRACTED!" returned status code 128:stdout: stderr: fatal: refusing to merge unrelated histories{code} FYI I remove the sensitive date from the output and replaced with !INFO_EXTRACTED!  
 

  
  

[JIRA] (JENKINS-45771) Disable shallow clone when we know a merge will take place

2018-04-17 Thread sherman.y...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Shiqi Yang reopened an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 I found a case where this bug still applies in parallel stages, reopen this one since I think it is the same issue but please let me know if it is not and I can open another one environment: jenkins 2.89.3 github-branch-source-plugin 2.32.2 I have a multibranch project setup with  `discover the pull requests from origin` `merge pull request with target` fetch all tags shallow clone  I also have Basic Branch Build Strategies Plugin installed to stop the build storm when we scan repo but I don't think it is related my pipeline file has 2 parallel stages and one of the stages has its own node {} section to specify the builder label and workspace path. it looks like this (this is almost the same example of https://jenkins.io/blog/2017/09/25/declarative-1, only difference here is that I have customWorkspace specified on the nodes to reuse the local code repo in the hope to save some time on git clone, our git repo is huge): 

 

pipeline {
 agent none
stages {
stage('Run Tests') {
parallel {
stage('Test 1') {
agent {
label "windows"
customWorkspace "${env.HOME}/TEST1"
}
steps {
bat "run-tests.bat"
}
post {
always {
junit "**/TEST-*.xml"
}
}
}
stage('Test On Linux') {
agent {
label "linux"
customWorkspace "${env.HOME}/TEST2"
}
steps {
sh "run-tests.sh"
}
post {
always {
junit "**/TEST-*.xml"
}
}
}
}
}
}
}
 

 the error I am seeing is that when the pipeline enters the parallel stages, especially after the workspace switch, it will fail to merge if the PR is couple of commits behind master because the head of master is checked out without git history. ( I logged in to the builder after the failure and manually verified that in the workspace) it seems that removing the customWorkspace will help resolve this 

 

> /usr/local/bin/git rev-parse --is-inside-work-tree # timeout=10

Fetching changes from the remote Git repository

 > /usr/local/bin/git config remote.origin.url !INFO_EXTRACTED! # timeout=10

Fetching upstream changes from !INFO_EXTRACTED!

 > /usr/local/bin/git --version # timeout=10

using GIT_ASKPASS to set credentials JENKINS_GH

 > /usr/local/bin/git fetch --tags --progress !INFO_EXTRACTED! +refs/pull/!INFO_EXTRACTED!/head:refs/remotes/origin/PR-!INFO_EXTRACTED! +refs/heads/master:refs/remotes/origin/master # timeout=60

Merging remotes/origin/master commit !INFO_EXTRACTED! into PR head commit !INFO_EXTRACTED!

 > /usr/local/bin/git config core.sparsecheckout # timeout=10

 > /usr/local/bin/git checkout -f !INFO_EXTRACTED!

 > /usr/local/bin/git merge !INFO_EXTRACTED! # timeout=10

 > /usr/local/bin/git config core.sparsecheckout # timeout=10

 > /usr/local/bin/git checkout -f !INFO_EXTRACTED!

Command "/usr/local/bin/git merge !INFO_EXTRACTED!" returned status code 128:

stdout: 

stderr: fatal: refusing to merge unrelated histories