Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NPE in GHPerson.populate #395

Closed
liborbitala opened this issue Nov 7, 2017 · 3 comments
Closed

NPE in GHPerson.populate #395

liborbitala opened this issue Nov 7, 2017 · 3 comments

Comments

@liborbitala
Copy link

Hi,

after updating to version 1.90 of GitHub API in our Jenkins, we have a problem when getting info about author of PullRequest for some users. It is blocking our automation of Jenkins builds using Github Pull Request Builder plugin. Interesting thing is that the issue is happening only for some users' Pull Requests. For others everything works fine. We haven't found any suspicious pattern in users' settings.

The error looks as follows:

Unable to handle comment for PR# 266904472, repo: xxx/xxx-xxx
java.lang.NullPointerException
at org.kohsuke.github.GHPerson.populate(GHPerson.java:44)
at org.kohsuke.github.GHPerson.getEmail(GHPerson.java:231)
at org.jenkinsci.plugins.ghprb.GhprbPullRequest.getAuthorEmail(GhprbPullRequest.java:726)
at org.jenkinsci.plugins.ghprb.GhprbBuilds.build(GhprbBuilds.java:54)
at org.jenkinsci.plugins.ghprb.GhprbPullRequest.build(GhprbPullRequest.java:417)
at org.jenkinsci.plugins.ghprb.GhprbPullRequest.tryBuild(GhprbPullRequest.java:410)
at org.jenkinsci.plugins.ghprb.GhprbPullRequest.check(GhprbPullRequest.java:244)
at org.jenkinsci.plugins.ghprb.GhprbRepository.onIssueCommentHook(GhprbRepository.java:342)
at org.jenkinsci.plugins.ghprb.GhprbTrigger.handleComment(GhprbTrigger.java:637)
at org.jenkinsci.plugins.ghprb.GhprbRootAction$1.run(GhprbRootAction.java:233)

According to report in Jenkins Jira (https://issues.jenkins-ci.org/browse/JENKINS-47848) it seems that downgrade to 1.86 should help, but we need to use 1.90 because of other issues.

Could you look onto it or provide some workaround?

Thank you.

@Rechi
Copy link
Contributor

Rechi commented Nov 9, 2017

maybe #396 fixes your (and my) issue

@Rechi
Copy link
Contributor

Rechi commented Nov 10, 2017

@liborbitala try github-api-1.90-NPE.zip this is 1.90 including my NPE fix.
For me it looks like it solved the issue.

@kohsuke
Copy link
Collaborator

kohsuke commented Jan 13, 2018

Looks like #396 is merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants