2

My company just upgraded out GHE instance to 2.17 and I am having a hell of a time with Jenkins now. Up until the upgrade everything worked, but now whenever a pull request is built, I get the following error:

19:17:43 Connecting to https://xxxxxxxxxxxxxxxx/api/v3 using cxxxxxxxxxxxxxn/****** (Credentials to access the xxxxxxxxxxx openstack api)

GitHub has been notified of this commit’s build result

com.fasterxml.jackson.core.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', 'false' or 'null')
 at [Source: (StringReader); line: 1, column: 2]
    at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1804)
    at com.fasterxml.jackson.core.base.ParserMinimalBase._reportError(ParserMinimalBase.java:693)
    at com.fasterxml.jackson.core.base.ParserMinimalBase._reportUnexpectedChar(ParserMinimalBase.java:591)
    at com.fasterxml.jackson.core.json.ReaderBasedJsonParser._handleOddValue(ReaderBasedJsonParser.java:1902)
    at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.nextToken(ReaderBasedJsonParser.java:757)
    at com.fasterxml.jackson.databind.ObjectMapper._initForReading(ObjectMapper.java:4142)
    at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:4001)
    at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3005)
    at org.kohsuke.github.Requester.parse(Requester.java:629)
Caused: org.kohsuke.github.HttpException: Server returned HTTP response code: 200, message: 'OK' for URL: https://xxxxxxxxxxxxxxx/api/v3/users/AT
    at org.kohsuke.github.Requester.parse(Requester.java:646)
    at org.kohsuke.github.Requester.parse(Requester.java:607)
    at org.kohsuke.github.Requester._to(Requester.java:285)
    at org.kohsuke.github.Requester.to(Requester.java:247)
    at org.kohsuke.github.GitHub.getUser(GitHub.java:398)
    at org.jenkinsci.plugins.github_branch_source.GitHubSCMFileSystem$BuilderImpl.build(GitHubSCMFileSystem.java:304)
    at jenkins.scm.api.SCMFileSystem.of(SCMFileSystem.java:293)
    at org.jenkinsci.plugins.workflow.multibranch.SCMBinder.create(SCMBinder.java:103)
    at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:293)
    at hudson.model.ResourceController.execute(ResourceController.java:97)
    at hudson.model.Executor.run(Executor.java:429)
Finished: FAILURE

I am by no means a Jenkins expert, but this is really puzzling me. Jobs off the master branch run fine, jobs based on a tag run fine. It is only jobs off of a PR that break. Also, how does a response code of 200 lead to an error?

I tried adding a logger to see if I could get the raw output from the web call but I had no luck getting the right level so I could actually see it if it is outputted.

I have tried google and no luck, it gets drowned out by the library exception. I have also been trying to look up issues with GHE and I have yet to find anything. I am hoping that someone can point me in the direction on how I can get the raw output from the webcall as I think that will point me in the direction I need to go to fix the problem.

2 Answers 2

3

With the hint in the above comment, we fixed our build pipeline. We did it in Jenkins by changing a character in the Repository URL from lowercase to an uppercase. It sounds very odd but it works, and without it, it breaks again. Probably a bug in the last update.

In your pipeline go to configure. Under Branch Sources, change one of the characters to uppercase.

Repository HTTPS URL https://git.yourenterprisedomain.com/Change/intoUppercase

1
  • I ran into the same issue with GHE 2.21.x, and resolved it the same way, thank you. It's just weird.
    – Patrice M.
    Commented Dec 7, 2020 at 19:23
2

There was a change in the handling of names in 2.17 to support organizations being allowed to have spaces in their name. Essentially "AT" != "at" where pre 2.17 they were treated as the same.

Updating the organization in the organization folder configuration allowed me to solve this problem.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .