[JIRA] (JENKINS-39393) When "origin branches also filed as PRs" is set, FileNotFoundException from malformed GitHub "open PR" query

7 views
Skip to first unread message

rbellamy@terradatum.com (JIRA)

unread,
Oct 31, 2016, 11:26:01 PM10/31/16
to jenkinsc...@googlegroups.com
G. Richard Bellamy created an issue
 
Jenkins / Bug JENKINS-39393
When "origin branches also filed as PRs" is set, FileNotFoundException from malformed GitHub "open PR" query
Issue Type: Bug Bug
Assignee: Kohsuke Kawaguchi
Components: github-organization-folder-plugin
Created: 2016/Nov/01 3:25 AM
Environment: Jenkins: 2.27
Plugin: 1.4 and 1.5
Labels: github
Priority: Blocker Blocker
Reporter: G. Richard Bellamy

When trying to re-scan our GitHub Org, and we have set the "Build origin branches also filed as PRs" or really any of the "origin PR" settings, I see the following exception:

Nov 01, 2016 3:02:06 AM SEVERE hudson.model.Executor finish1
Executor threw an exception
java.lang.Error: java.io.FileNotFoundException: {"message":"Server Error","documentation_url":"https://developer.github.com/v3"}
	at org.kohsuke.github.Requester$PagingIterator.fetch(Requester.java:433)
	at org.kohsuke.github.Requester$PagingIterator.hasNext(Requester.java:400)
	at org.kohsuke.github.PagedIterator.fetch(PagedIterator.java:44)
	at org.kohsuke.github.PagedIterator.hasNext(PagedIterator.java:32)
	at org.kohsuke.github.PagedIterable.asList(PagedIterable.java:42)
	at org.kohsuke.github.GHRepository.getPullRequests(GHRepository.java:648)
	at org.jenkinsci.plugins.github_branch_source.GitHubSCMSource.doRetrieve(GitHubSCMSource.java:381)
	at org.jenkinsci.plugins.github_branch_source.GitHubSCMSource.retrieve(GitHubSCMSource.java:365)
	at jenkins.scm.api.SCMSource.fetch(SCMSource.java:148)
	at jenkins.scm.api.SCMSource.retrieve(SCMSource.java:232)
	at jenkins.scm.api.SCMSource.fetch(SCMSource.java:177)
	at jenkins.branch.MultiBranchProjectFactory$BySCMSourceCriteria$1.call(MultiBranchProjectFactory.java:157)
	at jenkins.branch.MultiBranchProjectFactory$BySCMSourceCriteria$1.call(MultiBranchProjectFactory.java:154)
	at jenkins.branch.OrganizationFolder.withSCMSourceCriteria(OrganizationFolder.java:255)
	at jenkins.branch.MultiBranchProjectFactory$BySCMSourceCriteria.recognizes(MultiBranchProjectFactory.java:154)
	at jenkins.branch.OrganizationFolder$1$1.complete(OrganizationFolder.java:165)
	at org.jenkinsci.plugins.github_branch_source.GitHubSCMNavigator.add(GitHubSCMNavigator.java:323)
	at org.jenkinsci.plugins.github_branch_source.GitHubSCMNavigator.visitSources(GitHubSCMNavigator.java:276)
	at jenkins.branch.OrganizationFolder.computeChildren(OrganizationFolder.java:125)
	at com.cloudbees.hudson.plugins.folder.computed.ComputedFolder.updateChildren(ComputedFolder.java:157)
	at com.cloudbees.hudson.plugins.folder.computed.FolderComputation.run(FolderComputation.java:122)
	at hudson.model.ResourceController.execute(ResourceController.java:98)
	at hudson.model.Executor.run(Executor.java:401)
Caused by: java.io.FileNotFoundException: {"message":"Server Error","documentation_url":"https://developer.github.com/v3"}
	at org.kohsuke.github.Requester.handleApiError(Requester.java:592)
	at org.kohsuke.github.Requester$PagingIterator.fetch(Requester.java:429)
	... 22 more
Caused by: java.io.FileNotFoundException: https://api.github.com/repos/terradatum/node-spritesheet/pulls?state=open
	at com.squareup.okhttp.internal.huc.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:243)
	at com.squareup.okhttp.internal.huc.DelegatingHttpsURLConnection.getInputStream(DelegatingHttpsURLConnection.java:210)
	at com.squareup.okhttp.internal.huc.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:25)
	at org.kohsuke.github.Requester.parse(Requester.java:524)
	at org.kohsuke.github.Requester.access$200(Requester.java:68)
	at org.kohsuke.github.Requester$PagingIterator.fetch(Requester.java:424)
	... 22 more

And when I try the URL seen in the exception: https://api.github.com/repos/terradatum/node-spritesheet/pulls?state=open

I see the following:

{
  "message": "Server Error",
  "documentation_url": "https://developer.github.com/v3"
}

The symptom on the UI is the "Failure: NOT_BUILT" status.

Yes the automation user connecting to our GitHub org is an admin in the org. No, this is not the typical case where the plugin is failing to create, or delete, or even see the hook - this is about a failed API call to GitHub when the plugin is looking for open PRs.

Maybe a regression introduced during the JENKINS-37253 fix?

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

stephen.alan.connolly@gmail.com (JIRA)

unread,
Dec 19, 2016, 5:12:02 AM12/19/16
to jenkinsc...@googlegroups.com
Stephen Connolly resolved as Won't Fix
 

The GitHub Org Folders plugin is being tombstoned.

The functionality provided by the GitHub Org Folders plugin has been significantly refactored and migrated to the GitHub Branch Source plugin.

Please verify if this issue is an issue with GitHub Branch Source 2.0.0-beta-1 (available from the experimental update center now or 2.0.0 (available in early January 2017)

Change By: Stephen Connolly
Status: Open Resolved
Resolution: Won't Fix

rbellamy@terradatum.com (JIRA)

unread,
Dec 19, 2016, 11:02:01 AM12/19/16
to jenkinsc...@googlegroups.com
G. Richard Bellamy commented on Bug JENKINS-39393
 
Re: When "origin branches also filed as PRs" is set, FileNotFoundException from malformed GitHub "open PR" query

Stephen Connolly I just added the experimental update center to my Jenkins host and I'm not seeing the GitHub Branch Source option?

rbellamy@terradatum.com (JIRA)

unread,
Dec 19, 2016, 11:03:01 AM12/19/16
to jenkinsc...@googlegroups.com

rbellamy@terradatum.com (JIRA)

unread,
Dec 19, 2016, 12:02:03 PM12/19/16
to jenkinsc...@googlegroups.com

Found it... the filter built into the plugin manager wasn't finding it... actually had to use the "Find in page" functionality of my browser...

stephen.alan.connolly@gmail.com (JIRA)

unread,
Dec 19, 2016, 12:06:01 PM12/19/16
to jenkinsc...@googlegroups.com

It should have been showing up on the updates tab if you have the previous one installed

stephen.alan.connolly@gmail.com (JIRA)

unread,
Dec 19, 2016, 12:08:01 PM12/19/16
to jenkinsc...@googlegroups.com

Please be advised that you will need to either upgrade to the GHOF tombstone release 1.6-beta-1 or uninstall the GHOF plugin

Recommended is to upgrade to the GHOF tombstone if you have GHOF installed as that will migrate your data... then after all projects have been indexed once you can uninstall the GHOF plugin

Reply all
Reply to author
Forward
0 new messages