-
Notifications
You must be signed in to change notification settings - Fork 20
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
Improper URL for GitHub Enterprise #178
Comments
We're also getting this. |
Same problem here: |
+1 |
The same issue is open on the official bug tracker as well: https://issues.jenkins-ci.org/browse/JENKINS-24145 |
+1 |
1 similar comment
+1 |
@DavidTanner was this one of the bugs you address between 1.14 - 1.14-3? |
I have not yet, but i will see about doing that today.
|
The URL you are using is invalid, it should be /api/v3 I don't see anywhere that anything is being appended. The only other time I see where it says file not found is if you don't have an API key setup for the plugin. |
I have reproduced the problem in the debugger too using my GitHub Enterprise. The trouble seems to be in pr.listCommits() in https://github.com/jenkinsci/ghprb-plugin/blob/master/src/main/java/org/jenkinsci/plugins/ghprb/GhprbPullRequest.java#L219. That method is of course in the GHPullRequest class which is outside of the plugin. Follow the rabbit, and it gets you to https://github.com/kohsuke/github-api/blob/master/src/main/java/org/kohsuke/github/GitHub.java#L231 where our apiUrl = "https://github.mysite.com/api/v3" is combined with tailApiUrl="/api/v3/repos/myrepo/myapp/pulls/7/commits". I hope this helps. I'm not sure whether the bug is in the API or in the plugin or whether there's a workaround. |
This is what I have configure for GitHub server api URL: This is from my Jenkins log: Aug 19, 2014 5:33:00 AM WARNING hudson.triggers.Trigger checkTriggers org.jenkinsci.plugins.ghprb.GhprbTrigger.run() failed for Where would the extra /api/v3 be coming from? On Tue, Aug 19, 2014 at 12:22 PM, David Tanner notifications@github.com
|
The extra /api/v3 is coming in when GHPullRequest line 199 creates just the path and sends it down the rabbit hole, where GitHub.java line 231 sees it is just the path and appends it to the main apiurl. Since the list commits is new, I am going to say it is at fault. I can add a workaround to the plugin till it is fixed, or we just create the bug against the github project and wait for the patch. I am good with either one, but I do know how I would fix it if nobody wants to wait. |
Created hub4j/github-api#116 for github-api |
Thanks, @DavidTanner. |
@DavidTanner yeah seriously, thanks for the quick turn around on that 👍 |
👍 |
I added a try-catch in version 1.14-5 that will fix this issue. Hopefully they release the fix in github-api, but for now this will suffice. |
Running 1.14-5 I can tell you the Bug still exists (at least I still get the warning for /api/v3/api/v3). Is there any work-arround for me now? |
The error will be printed, but it shouldn't mark the job as failed. Can On Thu, Aug 21, 2014 at 12:20 PM, Tim Buchwaldt notifications@github.com
David Tanner 3 Nephi 5:13 http://lds.org/scriptures/bofm/3-ne/5.13?lang=eng#12 Behold, |
It doesn't fetch the new PRs as it seems (I use the scheduled fetch, not the HTTP hooks). Tim
|
I am also using the cron instead of hooks, but I am using github.com I don't understand what your error is exactly. I assumed the FileNotFound exception could be caught and ignored in PullRequest. Do you have more information on what you are seeing? |
Hey,
The Github-Hostname is set to The Github Hook Log for this build says |
FileNotFoundException should be caught by the catch statement. I am not sure why this is happening still. If it can't be caught, then we will just have to wait for them to fix it on their end. I am sorry. |
I think this issue should be re-opened, even if the bug is caused by the dependency on the github api plugin - the end result is the same. All us enterprise github users want our pull request plugin back and open issues get more visibility on the problem! |
I am receiving a similar error - although I am not using enterprise githubt - I just have my github api set to Here is the error:
Any thoughts? |
Now that the PR over on the github-api repo has been merged in, does anything extra have to do done for this plugin to pickup the new version? I'm hoping nothing more than a uninstall + reinstall is needed. |
The if statement i added needs to be removed, i will change the code and
|
👍 Maurice W. Sent from a mobile device. Please forgive any typos.
|
Anyone experiencing this bug still? |
i get this error: java.io.FileNotFoundException: https://github.com/eduacsp/pm-75-leiloes.git/user |
Remove the .git portion of the url |
I did, but it doesnt work at all. I think, the problem is '/user' portion: java.io.FileNotFoundException: https://github.com/eduacsp/pm-75-leiloes/user |
You need to have api.github.com also. |
Check the readme to make sure the api url is correct in all locations. The setting globally isnt supposed to point directly to any project, just api.github.com |
This is my configuration: I get this error: |
The api url needs to be just https://api.github.com |
Thx!..works fine now |
Jenkins version: 1.572
Plugin version: 1.13
Using GitHub Enterprise: yes
If you take a look at the log output below, there is a URL segment which is repeated (
/api/v3/api/v3
). This is causing the plugin to fail since that URL is not valid.I have double-checked my config section, and I do have the URL properly defined (with this value:
https://github.intenral.sw.com/api/v3/api/
).The text was updated successfully, but these errors were encountered: