[JIRA] [branch-api-plugin] (JENKINS-34728) Pull Request pipeline fails to checkout successive commits

6 views
Skip to first unread message

aburdajewicz@cloudbees.com (JIRA)

unread,
May 11, 2016, 5:33:01 AM5/11/16
to jenkinsc...@googlegroups.com
Allan BURDAJEWICZ commented on Bug JENKINS-34728
 
Re: Pull Request pipeline fails to checkout successive commits

This could be related somehow to JENKINS-34727

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265)
Atlassian logo

aburdajewicz@cloudbees.com (JIRA)

unread,
May 11, 2016, 5:33:02 AM5/11/16
to jenkinsc...@googlegroups.com
Allan BURDAJEWICZ created an issue
 
Jenkins / Bug JENKINS-34728
Issue Type: Bug Bug
Assignee: stephenconnolly
Components: branch-api-plugin, github-branch-source-plugin
Created: 2016/May/11 9:32 AM
Environment: core:1.642.4.2
github:1.17.1
github-api:1.75
github-branch-source:1.6
branch-api:1.7
Priority: Major Major
Reporter: Allan BURDAJEWICZ

How to reproduce

(Assuming you have a GitHub Organization folder with WebHooks already setup)

1. Fork a repo
2. Create a branch
3. Make a change
4. Make a commit
5. Create a pull request against the remote master
6. Commit successively multiple changes very quickly - 2/3 seconds interval
(Usually 5 commit suffice)
7. You should see the PR build failing with the following exception:

hudson.plugins.git.GitException: Could not checkout 67615299b8ef9ae83a60c72af7ca37cbfc879d4f 
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$9.execute(CliGitAPIImpl.java:1992) 
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1135) 
at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:109) 
at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:109) 
at org.jenkinsci.plugins.workflow.multibranch.SCMBinder.create(SCMBinder.java:87) 
at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:206) 
at hudson.model.ResourceController.execute(ResourceController.java:98) 
at hudson.model.Executor.run(Executor.java:410) 
Caused by: hudson.plugins.git.GitException: Command "git checkout -f 67615299b8ef9ae83a60c72af7ca37cbfc879d4f" returned status code 128: 
stdout: 
stderr: fatal: reference is not a tree: 67615299b8ef9ae83a60c72af7ca37cbfc879d4f

at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1719) 
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$500(CliGitAPIImpl.java:63) 
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$9.execute(CliGitAPIImpl.java:1984) 
... 7 more 
Finished: FAILURE

Example

Following have been committed within 10 seconds in that order:

1. 4fba098fd8127befb73e751f58d31129abfec323
2. 84765a178a5516dbabfb9d0cbf17ee08129a00c4 -> triggered branch indexing
3. 67615299b8ef9ae83a60c72af7ca37cbfc879d4f

Checking in the indexing logs, the Branch Indexing detected changes for PR-13, sha 84765a178a5516dbabfb9d0cbf17ee08129a00c4:

Changes detected in PR-13 (12d4896a25dcf71c7febc379f55e84841c4dde69 → 84765a178a5516dbabfb9d0cbf17ee08129a00c4)
Scheduled build for branch: PR-13

The next indexing logs, probably triggered by 67615299b8ef9ae83a60c72af7ca37cbfc879d4f, shows:

No changes detected in PR-13 (still at 84765a178a5516dbabfb9d0cbf17ee08129a00c4)

paul@paultyng.net (JIRA)

unread,
May 12, 2016, 1:49:01 PM5/12/16
to jenkinsc...@googlegroups.com
Paul Tyng commented on Bug JENKINS-34728
 
Re: Pull Request pipeline fails to checkout successive commits

I am getting this continuously on PR builds. I have the latest plugin versions. Not sure if there is something I could do to address it on my end.

amuniz@cloudbees.com (JIRA)

unread,
May 13, 2016, 12:15:02 PM5/13/16
to jenkinsc...@googlegroups.com
Antonio Muñiz closed an issue as Fixed
 
Change By: Antonio Muñiz
Status: Open Closed
Resolution: Fixed

aburdajewicz@cloudbees.com (JIRA)

unread,
Jun 22, 2016, 12:05:01 AM6/22/16
to jenkinsc...@googlegroups.com
Allan BURDAJEWICZ commented on Bug JENKINS-34728
 
Re: Pull Request pipeline fails to checkout successive commits

Can still reproduce with the latest:

branch-api:1.10
github-branch-source:1.7
github-pull-request-build:1.10

Reproduce

I have a repo, a fork and an open PR:

  • Create an GitHub Organization Folder for the support-team user
  • Register WebHook on GHE for the repo
  • Commit successively multiple changes to the fork very quickly - 5 seconds interval
  • You should see the PR build failing with the following exception:
hudson.plugins.git.GitException: Could not checkout 67615299b8ef9ae83a60c72af7ca37cbfc879d4f 
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$9.execute(CliGitAPIImpl.java:1992) 
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1135) 
at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:109) 
at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:109) 
at org.jenkinsci.plugins.workflow.multibranch.SCMBinder.create(SCMBinder.java:87) 
at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:206) 
at hudson.model.ResourceController.execute(ResourceController.java:98) 
at hudson.model.Executor.run(Executor.java:410) 
Caused by: hudson.plugins.git.GitException: Command "git checkout -f 67615299b8ef9ae83a60c72af7ca37cbfc879d4f" returned status code 128: 
stdout: 
stderr: fatal: reference is not a tree: 67615299b8ef9ae83a60c72af7ca37cbfc879d4f

at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1719) 
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$500(CliGitAPIImpl.java:63) 
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$9.execute(CliGitAPIImpl.java:1984) 
... 7 more 
Finished: FAILURE
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

aburdajewicz@cloudbees.com (JIRA)

unread,
Jun 22, 2016, 12:05:01 AM6/22/16
to jenkinsc...@googlegroups.com
Allan BURDAJEWICZ reopened an issue
 
Change By: Allan BURDAJEWICZ
Resolution: Fixed
Status: Closed Reopened

jglick@cloudbees.com (JIRA)

unread,
Jul 5, 2016, 1:09:01 PM7/5/16
to jenkinsc...@googlegroups.com
Jesse Glick assigned an issue to Unassigned
Change By: Jesse Glick
Component/s: branch-api-plugin
Assignee: stephenconnolly

jglick@cloudbees.com (JIRA)

unread,
Jul 5, 2016, 1:55:02 PM7/5/16
to jenkinsc...@googlegroups.com

jglick@cloudbees.com (JIRA)

unread,
Jul 5, 2016, 1:55:02 PM7/5/16
to jenkinsc...@googlegroups.com

jglick@cloudbees.com (JIRA)

unread,
Jul 5, 2016, 1:55:02 PM7/5/16
to jenkinsc...@googlegroups.com
Jesse Glick started work on Bug JENKINS-34728
 
Change By: Jesse Glick
Status: Open In Progress

jglick@cloudbees.com (JIRA)

unread,
Jul 5, 2016, 2:29:01 PM7/5/16
to jenkinsc...@googlegroups.com
Jesse Glick commented on Bug JENKINS-34728
 
Re: Pull Request pipeline fails to checkout successive commits

As I suspected, this is reproducible before, but not after, the refactoring in JENKINS-33161.

jglick@cloudbees.com (JIRA)

unread,
Jul 5, 2016, 2:32:01 PM7/5/16
to jenkinsc...@googlegroups.com

jglick@cloudbees.com (JIRA)

unread,
Jul 5, 2016, 3:38:45 PM7/5/16
to jenkinsc...@googlegroups.com
Jesse Glick resolved as Fixed
 
Change By: Jesse Glick
Status: In Progress Resolved
Resolution: Fixed
Reply all
Reply to author
Forward
0 new messages