[JIRA] (JENKINS-56538) Jenkins declarative pipelines sometimes is skipping "Checkout SCM" [possible solution is in the comment]

2019-05-04 Thread mnuzz...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Matt Nuzzaco commented on  JENKINS-56538  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Jenkins declarative pipelines sometimes is skipping "Checkout SCM" [possible solution is in the comment]   
 

  
 
 
 
 

 
 I'm seeing a similar set of errors on parallel builds, I am running Jenkins core v2.175 + all the latest versions of plugins (also running kubernetes plugin).  
 

  
 
 
 
 

 
 
 

 
 
 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-56538) Jenkins declarative pipelines sometimes is skipping "Checkout SCM" [possible solution is in the comment]

2019-04-08 Thread anewo...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Andrius Semionovas updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-56538  
 
 
  Jenkins declarative pipelines sometimes is skipping "Checkout SCM" [possible solution is in the comment]   
 

  
 
 
 
 

 
Change By: 
 Andrius Semionovas  
 
 
Summary: 
 Jenkins declarative pipelines sometimes is skipping "Checkout SCM"  [possible solution is in the comment]  
 

  
 
 
 
 

 
 
 

 
 
 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-56538) Jenkins declarative pipelines sometimes is skipping "Checkout SCM"

2019-04-08 Thread anewo...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Andrius Semionovas commented on  JENKINS-56538  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Jenkins declarative pipelines sometimes is skipping "Checkout SCM"   
 

  
 
 
 
 

 
 I found a workaround for this issue. Use `sleep` to make sure no two jobs will be launched on the same second. No more problems since.  

 

script {
def builds = [:]

for (i = 0; i < countries.size(); i++) {
def sleepInSec = i * 5
builds["Country $country"] = {
sleep(sleepInSec)

build job: env.JOB_NAME, parameters: [
string(name: 'COUNTRY', value: country),
]
}
}

parallel builds
}
 

    
 

  
 
 
 
 

 
 
 

 
 
 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-56538) Jenkins declarative pipelines sometimes is skipping "Checkout SCM"

2019-03-25 Thread anewo...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Andrius Semionovas commented on  JENKINS-56538  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Jenkins declarative pipelines sometimes is skipping "Checkout SCM"   
 

  
 
 
 
 

 
 Seems like I found a problem. I found failures happen because two parallel builds are using the same folder on slave machine: Success: 

 

Started by upstream project "android-release-by-tag/v8.31.0.0" build number 1
originally caused by:
 Push event for tag v8.31.0.0
13:55:46 Connecting to https://api.github.com using jenkins/** (Testing GitHub integration for multibranch pipelines)
Obtained Jenkinsfile from 9a50827efe20bbf7129e4c541f9057f10b0ec0e1
Running in Durability level: MAX_SURVIVABILITY
Loading library xxx-shared-libs@master
Attempting to resolve master from remote references...
 > git --version # timeout=10
 > git ls-remote -h g...@github.com:xxx/jenkins-shared-libs.git # timeout=10
Found match: refs/heads/master revision e1fb61690198e5d487ac3a56f96cc5bb35ec80cf
No credentials specified
Cloning the remote Git repository
Cloning with configured refspecs honoured and without tags
Cloning repository g...@github.com:xxx/jenkins-shared-libs.git
 > git init /var/lib/jenkins/workspace/android-release-by-tag_v8.31.0.0@libs/xxx-shared-libs@10 # timeout=10
Fetching upstream changes from g...@github.com:xxx/jenkins-shared-libs.git
 > git --version # timeout=10
 > git fetch --no-tags --progress g...@github.com:xxx/jenkins-shared-libs.git +refs/heads/*:refs/remotes/origin/*
 > git config remote.origin.url g...@github.com:xxx/jenkins-shared-libs.git # timeout=10
 > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
 > git config remote.origin.url g...@github.com:xxx/jenkins-shared-libs.git # timeout=10
Fetching without tags
Fetching upstream changes from g...@github.com:xxx/jenkins-shared-libs.git
 > git fetch --no-tags --progress g...@github.com:xxx/jenkins-shared-libs.git +refs/heads/*:refs/remotes/origin/*
Checking out Revision e1fb61690198e5d487ac3a56f96cc5bb35ec80cf (master)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f e1fb61690198e5d487ac3a56f96cc5bb35ec80cf
Commit message: "Merge pull request #34 from xxx/fix/mistyped_variable"
[Pipeline] Start of Pipeline
[Pipeline] node
Running on slave in /var/lib/jenkins/workspace/android-release-by-tag_v8.31.0.0@8
[Pipeline] {
[Pipeline] stage
[Pipeline] { (Declarative: Checkout SCM)
[Pipeline] checkout
using credential github-jenkins-user 

   Fail:   

 

Started by upstream project "android-release-by-tag/v8.31.0.0" build number 1
originally caused by:
 Push event for tag v8.31.0.0
13:55:46 Connecting to https://api.github.com using jenkins/** (Testing GitHub integration for multibranch pipelines)
Obtained Jenkinsfile from 9a50827efe20bbf7129e4c541f9057f10b0ec0e1
Running in Durability level: MAX_SURVIVABILITY
Loading library xxx-shared-libs@master
Attempting to resolve master from remote references...
 > git --version # timeout=10
 > git ls-remote -h g...@github.com:xxx/jenkins-shared-libs.git # timeout=10
Found match: refs/heads/master revision e1fb61690198e5d487ac3a56f96cc5bb35ec80cf
No credentials specified
Cloning the remote Git repository
Cloning with configured refspecs honoured and without tags
Cloning 

[JIRA] (JENKINS-56538) Jenkins declarative pipelines sometimes is skipping "Checkout SCM"

2019-03-25 Thread anewo...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Andrius Semionovas updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-56538  
 
 
  Jenkins declarative pipelines sometimes is skipping "Checkout SCM"   
 

  
 
 
 
 

 
Change By: 
 Andrius Semionovas  
 
 
Labels: 
 docker pipeline  race-condition  scmworkflow  
 

  
 
 
 
 

 
 
 

 
 
 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-56538) Jenkins declarative pipelines sometimes is skipping "Checkout SCM"

2019-03-13 Thread anewo...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Andrius Semionovas updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-56538  
 
 
  Jenkins declarative pipelines sometimes is skipping "Checkout SCM"   
 

  
 
 
 
 

 
Change By: 
 Andrius Semionovas  
 

  
 
 
 
 

 
 Stacktrace:{code:java}java.nio.file.NoSuchFileException: /var/lib/jenkins/workspace/android_master@4/Dockerfile at sun.nio.fs.UnixException.translateToIOException(UnixException.java:86) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107) at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214) at java.nio.file.Files.newByteChannel(Files.java:361) at java.nio.file.Files.newByteChannel(Files.java:407) at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:384) at java.nio.file.Files.newInputStream(Files.java:152) at hudson.FilePath.read(FilePath.java:1974) at org.jenkinsci.plugins.workflow.steps.ReadFileStep$Execution.run(ReadFileStep.java:104) at org.jenkinsci.plugins.workflow.steps.ReadFileStep$Execution.run(ReadFileStep.java:94) at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Finished: FAILURE{code}This failure happens randomly only in parallel builds. Builds are launching on the same job. Script:{code:java}builds["Country $country"] = { build job: env.JOB_NAME, parameters: [ string(name: 'COUNTRY', value: country), booleanParam(name: 'APK', value: true), ]}{code} I found "SCM Checkout" was skipped in case of failure. I added two screenshots for the same parallel jobs.   {code:java}  [Pipeline] Start of Pipeline  [Pipeline]  nodeRunning  node Running  on  [ Jenkins |https://jenkins.vinted.net/computer/(master)/]  in /var/lib/jenkins/workspace/android_master@4  [Pipeline] {  [Pipeline] stage  [Pipeline]   { (Declarative: Agent Setup)[Pipeline] isUnix[Pipeline] readFile[Pipeline] }  [Pipeline] // stage  [Pipeline] }  [Pipeline] // node  [Pipeline] stage  [Pipeline] { (Declarative: Post Actions)  [Pipeline] script  [Pipeline]   {[Pipeline] }  [Pipeline] // script  Error when executing always post condition:{code}     At the end of the build, I am cleaning everything with:{code:java}cleanWs(){code}The problem appeared for the first time after upgrading to 2.150.2 LT with all plugins (to that date)  Also, another stacktrace accompany this error, but I am not sure if it is related:{code:java}Error when executing always post condition: java.lang.NullPointerException: Cannot invoke method startsWith() on null object at org.codehaus.groovy.runtime.NullObject.invokeMethod(NullObject.java:91) at 

[JIRA] (JENKINS-56538) Jenkins declarative pipelines sometimes is skipping "Checkout SCM"

2019-03-13 Thread anewo...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Andrius Semionovas created an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-56538  
 
 
  Jenkins declarative pipelines sometimes is skipping "Checkout SCM"   
 

  
 
 
 
 

 
Issue Type: 
  Bug  
 
 
Assignee: 
 Unassigned  
 
 
Attachments: 
 failing.png, success.png  
 
 
Components: 
 pipeline  
 
 
Created: 
 2019-03-13 09:49  
 
 
Environment: 
 Jenkins ver. 2.150.2 LT  Pipeline: 2.6 (other related plugins are latest to this day)  
 
 
Labels: 
 pipeline docker scmworkflow  
 
 
Priority: 
  Major  
 
 
Reporter: 
 Andrius Semionovas  
 

  
 
 
 
 

 
 Stacktrace: 

 

java.nio.file.NoSuchFileException: /var/lib/jenkins/workspace/android_master@4/Dockerfile
 at sun.nio.fs.UnixException.translateToIOException(UnixException.java:86)
 at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102)
 at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107)
 at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214)
 at java.nio.file.Files.newByteChannel(Files.java:361)
 at java.nio.file.Files.newByteChannel(Files.java:407)
 at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:384)
 at java.nio.file.Files.newInputStream(Files.java:152)
 at hudson.FilePath.read(FilePath.java:1974)
 at