-
Notifications
You must be signed in to change notification settings - Fork 15
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
Review panel not working - Gerrit 3.8.2 #57
Comments
Hmm that request seems to get rejected by gerrit for a number of reasons (a change already being merged being one of them). I'll make the extension continue on with execution (and the showing of the panel) even if that request fails. |
Should be fixed in the newest version ( |
updated, still same issue. review panel does not show the review I selected. also I noticed another error in the Gerrit log:
What I noticed in the browser that if I open that URL without an authentication cookie I get a denied immediately (no basic auth popup). Could it be that this endpoint need "preemptive auth"? Maybe the other one with the mergeable as well? I can work around this if I add the "GerritAccount" cookie as the list of always to send cookie. But then I have to remove the username / HTTP password from the settings. Of course I'd rather prefer the user/pass option than to update the settings every time the Gerrit server is restarted or after 30 days when the cookie is renewed. FYI: I'm also the Gerrit server admin - so I can check the server if you need logs from the backend. Can also do some debugging. Unfortunately I cannot reopen this issue. |
Yes every API call under
I'm wondering what you mean with "add the "GerritAccount" cookie as the list of always to send cookie". That's what setting the cookie authentication setting does right? Or do you mean entering the username/password combo and on top adding
That's nice, makes debugging a bit easier :) To find out what is causing this, let's rule out a couple of things:
|
Ah I just noticed you mentioned already testing this with CURL in the other issue... I'll come up with something new to test then |
So just |
#58 is not exactly the same. The
I meant that using the cookie authentication setting AND / OR (tried both) username/password did not work for the review panel to show up. What DID work was
IIRC it was not sufficient to only set the cookie authentication setting, only after adding it to the extra cookies it worked (with worked I mean I was able to get the review panel to show the comment box and the +1 / +2 settings. That being said, even with those settings from above we are NOT able to post a comment, that one still fails. |
For reference - asked about the accounts/self issue here: https://groups.google.com/g/repo-discuss/c/ne94hMyWiyw |
Just noted that maybe the logging is just off as there are always an accounts/self call in close proximity to the error (so if the calls are done async could be that the error belongs to the other call, not the mergeable one) The error for the post is
|
I've built a debugging version of the extension so I can better see what might be causing it. I've attached it as a zip-file since github does not allow uploading
It'll basically just to a request to (of course feel free to censor the actual contents of sensitive fields) |
Ahh I've found the issue regarding the cookie setting not actually being used. Something with VSCode secretly handing over a readonly proxy of an object. I've attached a zip file where that issue is fixed. I'm still not actually sure why the regular HTTP API isn't working but let's first confirm that this works and then we can tackle that :) |
unfortunately neither with the attached Zip nor with the 1.2.29 version I'm able to post a comment.
the two occurences of each are one for the click on "Submit patch" and one for "Send" |
Hmm I can't tell from the logs whether the zip file came across properly. I've re-packaged it to be sure. This time I've changed the |
I tried it, where should I see the 2? Was unable to find it, though it installed successfully and it also shows that it's outdated and could be updated to 1.2.29 but I do not see the 2 in the logs |
In the developer tools it spits out some logs starting with Are you sure it installed succesfully? Maybe uninstall the previous version first and then re-install the version I attached? |
Hmm I'm leaning towards this being an issue with Gerrit itself. What do you think? As you describe in your google groups post it works in an authenticated browser (aka cookie), via CURL with a cookie (again cookie) but not when using basic auth via CURL. That sounds like it's broken for any HTTP-requesting program, whether it be CURL or my extension. Submitting comments silently failing is sort of expected, it does require I could pour quite a bit of time into making it so there's another method of inferring |
sorry if I wasn't clear ;) posting comments fails also with the auth-cookie even if account/self is working :) Yes, regarding the issue with the http pass. But if you only need the accountId we could also set that via settings. At least that one won't change (in contrast to the account cookie which will expire eventually) |
Ahh alright. I've got another debug version for you to try. This one has a bunch of logging around the posting-comments process. Can you let me know what it spits out? The logging is again in the devtools and contains |
Ahh it's the request itself failing. Here's another version then to log why that is happening. |
Ah yeah again an authentication issue. Not really much I can do against this... At least the accountID issue could have been put into a setting but an action like this can't. Or do you have any other ideas? |
Hi,
I get an authentication error when trying to open a change in the review panel. Log messages:
Other calls work fine, also opening that URL in the browser is working fine (also using the same URL on CLI with curl works).
Not sure what the issue is, tried with the http password and with the auth-cookie - same result.
OS: WSL on Windows with Ubuntu 22.04
The text was updated successfully, but these errors were encountered: