[JIRA] (JENKINS-61924) json parsing error when fetching branches from github

1 view
Skip to first unread message

qsxyh123@gmail.com (JIRA)

unread,
Apr 15, 2020, 6:21:04 PM4/15/20
to jenkinsc...@googlegroups.com
sean qian created an issue
 
Jenkins / Bug JENKINS-61924
json parsing error when fetching branches from github
Issue Type: Bug Bug
Assignee: Kirill Merkushev
Components: github-api-plugin, github-branch-source-plugin, github-plugin
Created: 2020-04-15 22:20
Environment: GitHub Branch Source Plugin: 2.6.0
GitHub plugin: 1.29.5
GitHub API Plugin: 1.110
Branch API: 2.3.0
Jenkins: 2.164.3
Priority: Blocker Blocker
Reporter: sean qian

When fetching branches from the github repository, having the following error.

ERROR: [Wed Apr 15 18:09:01 EDT 2020] Could not fetch branches from source if this isn't set then all branches will be rebuilt on refCreated and refDeleted events
com.fasterxml.jackson.core.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (JSON String, Number, Array, Object or token 'null', 'true' or 'false')
 at [Source: (StringReader); line: 1, column: 2]
	at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1840)
	at com.fasterxml.jackson.core.base.ParserMinimalBase._reportError(ParserMinimalBase.java:712)
	at com.fasterxml.jackson.core.base.ParserMinimalBase._reportUnexpectedChar(ParserMinimalBase.java:637)
	at com.fasterxml.jackson.core.json.ReaderBasedJsonParser._handleOddValue(ReaderBasedJsonParser.java:1916)
	at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.nextToken(ReaderBasedJsonParser.java:772)
	at com.fasterxml.jackson.databind.ObjectReader._initForReading(ObjectReader.java:357)
	at com.fasterxml.jackson.databind.ObjectReader._bindAndClose(ObjectReader.java:1704)
	at com.fasterxml.jackson.databind.ObjectReader.readValue(ObjectReader.java:1261)
	at org.kohsuke.github.GitHubResponse.parseBody(GitHubResponse.java:85)
	at org.kohsuke.github.GitHubPageIterator.lambda$fetch$0(GitHubPageIterator.java:145)
	at org.kohsuke.github.GitHubClient.createResponse(GitHubClient.java:406)
	at org.kohsuke.github.GitHubClient.sendRequest(GitHubClient.java:360)
Caused: org.kohsuke.github.HttpException: Server returned HTTP response code: 200, message: '304 Not Modified' for URL

 

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.12#713012-sha1:6e07c38)
Atlassian logo

mike.erickson75@gmail.com (JIRA)

unread,
Apr 17, 2020, 7:06:03 PM4/17/20
to jenkinsc...@googlegroups.com
Mike Erickson commented on Bug JENKINS-61924
 
Re: json parsing error when fetching branches from github

I have the same problem for 1 repo (others work)

Jenkins 2.232
git 4.2.2
git-client 3.2.1
git-server 1.9
github 1.29.5
github-api 1.111
github-branch-source 2.6.0
github-organization-folder 1.6

 ERROR: [Fri Apr 17 15:03:39 PDT 2020] Could not fetch sources from navigator org.jenkinsci.plugins.github_branch_source.GitHubSCMNavigator@21f39e43


com.fasterxml.jackson.core.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (JSON String, Number, Array, Object or token 'null', 'true' or 'false')
at [Source: (StringReader); line: 1, column: 2]
at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1840)
at com.fasterxml.jackson.core.base.ParserMinimalBase._reportError(ParserMinimalBase.java:712)
at com.fasterxml.jackson.core.base.ParserMinimalBase._reportUnexpectedChar(ParserMinimalBase.java:637)
at com.fasterxml.jackson.core.json.ReaderBasedJsonParser._handleOddValue(ReaderBasedJsonParser.java:1916)
at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.nextToken(ReaderBasedJsonParser.java:772)
at com.fasterxml.jackson.databind.ObjectReader._initForReading(ObjectReader.java:357)
at com.fasterxml.jackson.databind.ObjectReader._bindAndClose(ObjectReader.java:1704)
at com.fasterxml.jackson.databind.ObjectReader.readValue(ObjectReader.java:1261)
at org.kohsuke.github.GitHubResponse.parseBody(GitHubResponse.java:85)
at org.kohsuke.github.GitHubPageIterator.lambda$fetch$0(GitHubPageIterator.java:145)
at org.kohsuke.github.GitHubClient.createResponse(GitHubClient.java:406)
at org.kohsuke.github.GitHubClient.sendRequest(GitHubClient.java:360)

Caused: org.kohsuke.github.HttpException: Server returned HTTP response code: 200, message: '304 Not Modified' for URL: https://github.xxx/api/v3/repos/xxx/contents/?ref=refs%2Fheads%2Fmaster
at org.kohsuke.github.GitHubClient.interpretApiError(GitHubClient.java:445)

 

 

 

mike.erickson75@gmail.com (JIRA)

unread,
Apr 17, 2020, 8:14:03 PM4/17/20
to jenkinsc...@googlegroups.com
Mike Erickson edited a comment on Bug JENKINS-61924

 

 
Edit: 

I tried this but no luck   [https://superuser.com/questions/1459241/jenkins-and-github-enterprise-2-17-failing-pull-request-builds-only]

I made a commit on the repo (just changed a readme file) and it re-scanned and it worked. 

 

bitwiseman@gmail.com (JIRA)

unread,
Apr 24, 2020, 1:44:03 PM4/24/20
to jenkinsc...@googlegroups.com
Liam Newman assigned an issue to Liam Newman
 
Change By: Liam Newman
Assignee: Kirill Merkushev Liam Newman

bitwiseman@gmail.com (JIRA)

unread,
Apr 24, 2020, 1:48:03 PM4/24/20
to jenkinsc...@googlegroups.com
Liam Newman commented on Bug JENKINS-61924
 
Re: json parsing error when fetching branches from github

So, this is an intermittent failure? 

Could one of you file this as an issue for that github-api library (https://github.com/github-api/github-api) .  It is something that will need to be worked on there. 

 

bitwiseman@gmail.com (JIRA)

unread,
May 5, 2020, 7:03:03 PM5/5/20
to jenkinsc...@googlegroups.com
Liam Newman edited a comment on Bug JENKINS-61924
[~merickso] [~parabird]
So, this is an intermittent failure? 

Could one of you file this as an issue for that github-api library ([https://github.com/github-api/github-api]) .  It is something that will need to be worked on there. 

 
Reply all
Reply to author
Forward
0 new messages