Authorization - Central Thread
Use this issue to report any trouble you are having with setting up Le Git Graph.
Example:
- Infinite loading on the authorization page
- No commits shown even after successful authorization.
I am keeping this issue open for anyone to report such issues.
(NOTE: This doesn't indicate that the issue exists now. Things should work smooth. Please post here with screenshot if it doesn't.)
Hello there!
I'm seemingly experiencing some issues (as previously commented in #78 .
When I open a repo (in the screenshot you can see one of mine, but it's public) the Commit tab is added, with the button to
request authorization.
When I click on it, though, the popup page opens and it keep loading infinitely.
I've downloaded network requests from the popup page (nothing was present in the console)
scaria.dev_Archive [25-01-05 17-52-55].har.zip
and both console and requests from the initial Commit tab
console-export-2025-1-5_17-55-13.txt
github.com_Archive [25-01-05 17-54-36].har.zip
This is in my Raspberry running Bookworm (Debian 12) with FireFox 133.0 (aarch64).
@slim71 Thank you for providing the detailed information. I have made some changes to the authentication server. Mainly, this would show the actual error messages instead of an infinite loading. Could you check once more and let me know if there is any change/improvement?
NOTE: You might have to keep the console/devtools closed.
mmm it seems there's no difference? I navigated to the same repo, reclicked on the button but no different output... not even when keeping it open for a while
I did not gather logs this time, from what I understand it should have been shown in the page itself, right?
I'm also seeing an infinite load
@alexanderadam Strange. Can you try reloading the authorization loading page once? (or twice?)
Also, if none of that work, could you try the PAT way? (I have described it in the readme)
I've just tried again, this time on Windows (I have FireFox synced across devices) and I have an update.
As you can see from this (don't worry about the visible token: I've already deleted it!)
I've tried through a PAT, but it still wasn't working. To be fair, not even the "Set PAT" command seemed to work. So I decided to spend some time actually going through the requests through the dev console and I noticed some blocked requests.
Some are blocked with different codes, with NS_BINDING_ABORTED in the "Transferred" column. Others, though, were mentioning that some requests were blocked due to adblockers (I have AdBlocker Ultimate and uBlock Origin). :thinking: Without giving it much thought, I disabled all adblockers and tried again, from the start (so no PAT). As if by magic, it went through first try. :exploding_head:
Now, since I wasn't recording anything at that point, I'm not sure whether this could really be related or if it's by chance, so I'd like to actually retry this. @NirmalScaria is there a way to "clean" the permission without reinstalling the extension?
Hey, That sounds good.
There is a simple way to "clean" everything in this case. You can
- Go to Githug website.
- Open the devtools and go to "Application" tab
- Open local storage and select https://github.com
- Delete the keys "GithubOAuthToken" and "GithubUserName"
To remove the authorization from github side also, you can go to https://github.com/settings/applications
Then revoke access for "Le Git Graph". You will be able to start from the beginning of the auth flow.
Please let me know if you are able to confirm that adBlockers were causing the trouble. I can add it to readme.
Unfortunately, I can't reproduce a consistent behavior. :confused:
I've tried multiple times making sure the adblockers were disabled and all data for LeGitGraph authorization was cancelled (on GitHub side and in the local storage you mentioned).
I've come as far as having the actual prompt for authorization, but that's it.
Confirming that, LeGitGraph is correctly added in the Authorized OAuth Apps in GitHub, but I constantly remain stuck waiting in the popup page
and the process is not actuall finished: reloading the commit tab, it asks for authorization once again.
So I guess you can scratch my hyphothesis... :man_shrugging:
Unfortunately, I can't reproduce a consistent behavior. 😕
I've tried multiple times making sure the adblockers were disabled and all data for LeGitGraph authorization was cancelled (on GitHub side and in the local storage you mentioned). I've come as far as having the actual prompt for authorization, but that's it. Confirming that, LeGitGraph is correctly added in the Authorized OAuth Apps in GitHub, but I constantly remain stuck waiting in the popup page
and the process is not actuall finished: reloading the commit tab, it asks for authorization once again.
So I guess you can scratch my hyphothesis... 🤷♂️
I am having this same issue and was looking here for a solution. One of my repos is working fine with the extension but another prompts me to authorize Le Git Graph every time I go to the Commits tab. The pop-up opens and I select authorize and reload as instructed but it simply requests authorization again. This is the second repo I tried to authorize, the first I have no trouble with and no trouble viewing repos that have the extension authorized already such as this one.
@Itsmillertyme It doesn't look like the issue you are facing is the same as others'.
If you are able to access at least one repo's graph correctly, that means you have the correct token set in the browser. Then, for the repos which fail, there could be three chances.
-
The token you took does not have permission for the repo you are trying to visit. (This can happen if you gave permission only to public repos and you are trying to access a private repo. It can also happen if you are using a manually generated PAT and the PAT doesn't have permission for that repo).
-
You are trying to access a repo owned by an organisation, using OAuth. (OAuth doesn't work with repos owned by orgs. You need a PAT strictly).
-
The repo you are trying to visit has too many branches. (I have verified up to 300-400 branches. Over that, it could possibly fail.) If this is the case, the loading will take an unusual amount of time (like over 30 seconds) and then could trigger a fail.
Please test your case against these and let me know if you are able to narrow down the issue.
@Itsmillertyme It doesn't look like the issue you are facing is the same as others'.
If you are able to access at least one repo's graph correctly, that means you have the correct token set in the browser. Then, for the repos which fail, there could be three chances.
- The token you took does not have permission for the repo you are trying to visit. (This can happen if you gave permission only to public repos and you are trying to access a private repo. It can also happen if you are using a manually generated PAT and the PAT doesn't have permission for that repo).
- You are trying to access a repo owned by an organisation, using OAuth. (OAuth doesn't work with repos owned by orgs. You need a PAT strictly).
- The repo you are trying to visit has too many branches. (I have verified up to 300-400 branches. Over that, it could possibly fail.) If this is the case, the loading will take an unusual amount of time (like over 30 seconds) and then could trigger a fail.
Please test your case against these and let me know if you are able to narrow down the issue.
Hello, I appreciate the response and I have working on troubleshooting with what you suggested. The 2nd and 3rd options don't apply but I have been making sure permissions, as outlined in the 1st suggestion, are setup correctly. I uninstalled and reinstalled he extension and this time explicitly gave it access to private nd public repos but no change. The 'Commits' page says "Failed to fetch commits. Make sure your GitHub account has access to the repository." Which I definitely do since I created it. I don't use or really have any knowledge on PATs (Very new to using Github as a developer) so unless something with the token was messed up by default repo creation, I am not sure why that would be the case. Any other suggestions by chance?
Also having issues. On Firefox. Tried PAT and OAuth, neither worked. OAuth hangs at the "Authorizing Le Git Graph with GitHub Please wait while the authorisation process is completed with OAuth." message, clicking the "Set PAT" button with correctly set up PAT reloads the page back to the original state, with "Authorize with Le Git Graph" on the button. @NirmalScaria appreciate your work, hoping you have insight into possible ways to fix
Bump
Hey, @tonyjamesstark Sorry I have been busy. Could you try it once in chrome and let me know if the issue still happens?
Working on chrome! Firefox same deal though
@tonyjamesstark Few things to check.
- In devtools go to Storage tab > Local storage > https://github.com
Make sure that there are appropriate values for the keys
GithubOAuthTokenandGithubUserName. See the image below.
- If that is fine, go to any repo. (dont go to commits tab yet). open dev tools > network tab. Then click commits tab. Look for a new request to
https://api.github.com/graphql. Look at the response of that response and see if there are any error messages.
Ooh so it works if I manually put in the username as a locally stored variable. not otherwise though (tried 1 and 2) There is no request to api.github.com/graphql, only to .../_private/... something or other Hope this is helpful?