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

GitHub Desktop authorization does not work in Ubuntu 20.04 #632

Closed
kpurens opened this issue Dec 3, 2021 · 41 comments
Closed

GitHub Desktop authorization does not work in Ubuntu 20.04 #632

kpurens opened this issue Dec 3, 2021 · 41 comments
Labels
dbus Bug reports related to dbus setup unclear

Comments

@kpurens
Copy link

kpurens commented Dec 3, 2021

It opens the default browser (mine is Firefox version 94.0)

The browser says to wait while redirecting.

But the redirect never happens.

Browser console logs show some strange error "x-github-desktop-dev-auth unknown protocol"

Trying to authorize again shows a completely different error in browser: "The address wasn’t understood"

Seems completely broken.

@BaconCatBug
Copy link

I am having the same issue.

@tjbarber
Copy link

I am also having this issue.

@Xeddius
Copy link

Xeddius commented Dec 16, 2021

Doesn't work in latest version of Manjaro either. Appimage issues perhaps?

@BaconCatBug
Copy link

Version 2.6.3 works. If you can find the old version, install that.

@shiftkey
Copy link
Owner

A few questions to help guide the investigation:

  • what version of the package are you using?
  • which installer did you use?
  • any interesting log files you can share? ~/.config/GitHub Desktop/logs/ is where there are stored, organized by date

@BaconCatBug
Copy link

BaconCatBug commented Dec 18, 2021

2.9.6 .deb installer, Cinnamon desktop environment. No logs as I got the 2.6.3 deb and installed that instead.

@shiftkey
Copy link
Owner

No logs as I got the 2.6.3 deb and installed that instead.

It'd be great to see the underlying error(s) in the log with a more recent version as there's some details about how the app is launched that might be helpful here...

@pvojnisek
Copy link

Using pop!_os 21.10
Trying to log in using brave (and firefox) unsuccessfully. The url: x-github-desktop-dev-auth://oauth?code=xxx&state=xxx cannot be handed to the appimage.
The version installed from apt repository works flawlessly.

$sudo apt list github-desktop 
Listing... Done
github-desktop/impish,now 2.8.1-linux1 amd64 [installed]

Appimage version: GitHubDesktop-linux-2.9.6-linux1.AppImage

@AZHELLRGX
Copy link

Use deb format, don't use AppImage

@pavelhoral
Copy link

pavelhoral commented Feb 23, 2022

Redirect URL from GitHub's OAuth does not work for me and seems like this issue.

Logs:

2022-02-23T11:40:07.165Z - info: [main] Received possible protocol arguments: 4
2022-02-23T11:40:07.165Z - info: [main] Processing protocol url
2022-02-23T11:40:07.175Z - warn: [ui] Unknown URL action: unknown - payload: {"name":"unknown","url":"--enable-crashpad"}
2022-02-23T11:40:07.175Z - info: [ui] [Welcome] no sign in step found. ignoring...
2022-02-23T11:52:17.874Z - info: [main] Received possible protocol arguments: 4
2022-02-23T11:52:17.874Z - info: [main] Processing protocol url
2022-02-23T11:52:17.877Z - warn: [ui] Unknown URL action: unknown - payload: {"name":"unknown","url":"--enable-crashpad"}
2022-02-23T11:52:17.889Z - info: [ui] [Welcome] kind Authentication is the same as Authentication. ignoring...
2022-02-23T11:52:17.891Z - info: [ui] [Welcome] kind Authentication is the same as Authentication. ignoring...

My environment is Kubuntu 20.04 LTS). The above log / issue can be replicated also using xdg-open with "x-github-desktop-dev-auth://oauth?code=...".

UPDATE: Interesting observation - the redirect does not contain state parameter.

@AZHELLRGX
Copy link

AZHELLRGX commented Feb 23, 2022 via email

@jaromir-sukuba
Copy link

jaromir-sukuba commented Feb 23, 2022

I think I have similar or related problem. Version 2.9.9-linux2 (x64), installed from deb package (appimage version acts the same way) running Release Linux Mint 20.2 Uma 64-bit, Firefox 96.0 (64-bit).
After clicking File->Options->Accounts->Sign in I'm asked to use browser to login, I agree on this, browser ask me to confirm opening 'x-github-desktop-dev-auth', I choose Github desktop. Then browser loads empty page, github desktop jumps back into focus and waits here forever, no login performed.
Tried the same with chromium browser, no luck either.

2022-02-23T22:30:42.839Z - info: [ui] [AppStore] loading 0 repositories from store
2022-02-23T22:30:42.916Z - info: [ui] launching: 2.9.9-linux2 (Linux 5.4.0-90-generic)
2022-02-23T22:30:42.916Z - info: [ui] execPath: '/usr/lib/github-desktop/github-desktop'
2022-02-23T22:30:48.974Z - info: [ui] [SignInStore] initializing OAuth flow
2022-02-23T22:30:48.977Z - info: [main] opening in browser: https://github.com/login/oauth/authorize?client_id=3a72...
2022-02-23T22:30:51.673Z - info: [main] Received possible protocol arguments: 4
2022-02-23T22:30:51.673Z - info: [main] Processing protocol url
2022-02-23T22:30:51.675Z - warn: [ui] Unknown URL action: unknown - payload: {"name":"unknown","url":"--enable-crashpad"}

Authorize link was manually truncated.

@RatCaptain
Copy link

RatCaptain commented Feb 24, 2022

I think i have the same problem as @jaromir-sukuba

2022-02-24T13:20:23.655Z - info: [ui] [AppStore] loading 0 repositories from store
2022-02-24T13:20:23.733Z - info: [ui] launching: 2.9.9-linux2 (Linux 5.16.7-1-MANJARO)
2022-02-24T13:20:23.733Z - info: [ui] execPath: '/opt/github-desktop/github-desktop'
2022-02-24T13:20:34.366Z - info: [ui] [SignInStore] initializing OAuth flow
2022-02-24T13:20:34.372Z - info: [main] opening in browser: https://github.com/login/oauth/authorize?client_id=3a723b10ac5575cc5bb9&scope=repo%20user%20workflow&state=ea08f013-6a55-4440-886f-d6d570ff4f1c
2022-02-24T13:20:36.422Z - info: [main] Received possible protocol arguments: 4
2022-02-24T13:20:36.422Z - info: [main] Processing protocol url
2022-02-24T13:20:36.423Z - warn: [ui] Unknown URL action: unknown - payload: {"name":"unknown","url":"--enable-crashpad"}

System: Manjaro 21.2.3

Tried browsers:

  • Vivaldi
  • Chromium

I tried these two AUR packages, they both produced the same problem:
https://aur.archlinux.org/packages/github-desktop-bin
https://aur.archlinux.org/packages/github-desktop

Update:
Tried Versions:
(github-desktop-bin)
2.9.0 worked
2.9.6 worked
2.9.9(1) NOT worked
2.9.9(2) NOT worked

Solution:
If you login in the 2.9.6 version and then you install the 2.9.9 ver. The system remembers you and you can use the 2.9.9 verson. (Just don't logout, because you can't log back in the 2.9.9 ver)

@jaromir-sukuba
Copy link

@RatCaptain thank you!
I can confirm, uninstalling 2.9.9, installing deb 2.9.6 worked for me. Appimage 2.9.6 didn't work.
For now I'm probably going to stay with 2.9.6 unless I find an issue resolved in following releases.

@trombonefix
Copy link

trombonefix commented Feb 25, 2022

I'm running Manjaro Linux with Gnome. Gnome-Keyring is installed.
I've installed github desktop several times. The authentication redirects to github desktop but nothing happens. I've tried it with Firefox, Chrome and Opera. I think the problem is that github isn't added into the gnome-keyring or something else.
I'm about freaking out!
grafik

@Alessandro-filho
Copy link

I'm having the same problem on ParrotOs, I'm redirected from Chrome to GitHub, but it's just the "Login" ball animation and it doesn't ente
Captura de ecrã no 2022-02-25 05-20-18
r

@RatCaptain
Copy link

@trombonefix , @Alessandro-filho. Me and @jaromir-sukuba had the same problem.
Did you tried to downgrade github desktop to 2.6.6 ? It solved for us the problem.
Or if that didn't work , can you show us what the log says ?

@trombonefix
Copy link

trombonefix commented Feb 25, 2022

How do I downgrade. I can't find the 2.6.6 version in AUR.
Here are my logs of my last try:

Feb 25 12:41:22 manjaro systemd[1342]: Started app-flatpak-io.github.shiftey.Desktop-5634.scope.
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: Gtk-Message: 12:41:23.087: Failed to load module "canberra-gtk-module"
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: Gtk-Message: 12:41:23.087: Failed to load module "canberra-gtk-module"
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: [2:0225/124123.132955:ERROR:bus.cc(397)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: Datei oder Verzeichnis nicht gefunden
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: [2:0225/124123.133233:ERROR:bus.cc(397)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: Datei oder Verzeichnis nicht gefunden
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: LaunchProcess: failed to execvp:
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: xdg-settings
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: LaunchProcess: failed to execvp:
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: xdg-settings
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: [43:0225/124123.377428:ERROR:sandbox_linux.cc(377)] InitializeSandbox() called with multiple threads in process gpu-process.
Feb 25 12:41:27 manjaro io.github.shiftey.Desktop.desktop[5619]: [43:0225/124127.404060:ERROR:gl_surface_presentation_helper.cc(260)] GetVSyncParametersIfAvailable() failed for 1 times!
Feb 25 12:41:40 manjaro systemd[1342]: Started app-flatpak-io.github.shiftey.Desktop-5827.scope.
Feb 25 12:41:40 manjaro gnome-shell[5842]: [2 preload-host-spawn-strategy] Running: /app/bin/zypak-helper child - /app/github-desktop/github-desktop --type=zygote --enable-crashpad
Feb 25 12:41:40 manjaro systemd[1342]: Started app-flatpak-io.github.shiftey.Desktop-5852.scope.
Feb 25 12:43:04 manjaro systemd[1342]: app-gnome-io.github.shiftey.Desktop-5579.scope: Consumed 31.662s CPU time.

@Alessandro-filho
Copy link

How do I downgrade. I can't find the 2.6.6 version in AUR. Here are my logs of my last try:

Feb 25 12:41:22 manjaro systemd[1342]: Started app-flatpak-io.github.shiftey.Desktop-5634.scope. Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: Gtk-Message: 12:41:23.087: Failed to load module "canberra-gtk-module" Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: Gtk-Message: 12:41:23.087: Failed to load module "canberra-gtk-module" Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: [2:0225/124123.132955:ERROR:bus.cc(397)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: Datei oder Verzeichnis nicht gefunden Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: [2:0225/124123.133233:ERROR:bus.cc(397)] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: Datei oder Verzeichnis nicht gefunden Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: LaunchProcess: failed to execvp: Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: xdg-settings Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: LaunchProcess: failed to execvp: Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: xdg-settings Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null) Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: [43:0225/124123.377428:ERROR:sandbox_linux.cc(377)] InitializeSandbox() called with multiple threads in process gpu-process. Feb 25 12:41:27 manjaro io.github.shiftey.Desktop.desktop[5619]: [43:0225/124127.404060:ERROR:gl_surface_presentation_helper.cc(260)] GetVSyncParametersIfAvailable() failed for 1 times! Feb 25 12:41:40 manjaro systemd[1342]: Started app-flatpak-io.github.shiftey.Desktop-5827.scope. Feb 25 12:41:40 manjaro gnome-shell[5842]: [2 preload-host-spawn-strategy] Running: /app/bin/zypak-helper child - /app/github-desktop/github-desktop --type=zygote --enable-crashpad Feb 25 12:41:40 manjaro systemd[1342]: Started app-flatpak-io.github.shiftey.Desktop-5852.scope. Feb 25 12:43:04 manjaro systemd[1342]: app-gnome-io.github.shiftey.Desktop-5579.scope: Consumed 31.662s CPU time.

Friend, the downgrade I don't know either, but you can reinstall 2.6.6 as mentioned by @RatCaptain
Accessing this link: Here

@RatCaptain
Copy link

Yes and I'm sorry by downgrade i meant to just install an older version.

It seems like you have the same issue as us, but something else causing it. @trombonefix

In line 2 :Feb 25 12:41:23 manjaro io.github.shiftey.Desktop.desktop[5619]: Gtk-Message: 12:41:23.087: Failed to load module "canberra-gtk-module"
do you have these installed : libcanberra-gtk-module, libcanberra-gtk3-module ?
I don't see them in the dependency list, so i don't know why the github-desktop asking for it.

!! I don't know if an older version fixes for you the problem

If you want to install an older version you can use the link that @Alessandro-filho gave or you can do this:

How to get an older version:

  1. On the AUR github-desktop site on the right, click on the view changes
    Screenshot from 2022-02-25 15-20-53

  2. Click on the version you want to download

  3. Click on the "weirdly named".tar.gz link next to the "download: "
    Screenshot from 2022-02-25 15-27-48

  4. I recommend making a folder in the /home/"user name" (you can name it anything)
    Screenshot from 2022-02-25 15-30-45

  5. Extract the file you have downloaded and the put the extracted folder in the folder you had made.

  6. open the extracted folder and open it in the terminal

  7. In the terminal use the makepkg command

  8. sudo pacman -U "file name".tar.gz

@Alessandro-filho
Copy link

Mine worked with version 2.6.6

@RatCaptain
Copy link

Cool!
And if i'm right you had the same thing in the logs as me, am i right?
or is it the same as @trombonefix logs ?

@Alessandro-filho
Copy link

Frio! E se eu estiver certo, você tinha a mesma coisa nos logs que eu, estou certo? ou é o mesmo que os logs do @trombonefix ?

To be honest, I don't even know how to look at the logs, lol
I will start a Linux course now!
But mine at the moment was resolved by going back.

@RatCaptain
Copy link

RatCaptain commented Feb 25, 2022

I'm using linux for a year now. I don't know a lot of things yet.
until yesterday i didn't even known that how to install an older version, i figured out by my self :D.
and because i didn't find anything in the log that i can solve. I just guessed and tried the older version (thinking that maybe an older version don't have that problem)
if you see problems in the log, usually the first one causing a chain reaction and because of that it looks like a mess.
But i didn't found anything here

linux is a good brain teaser :D

@Alessandro-filho
Copy link

Really, it's nice to have something challenging 😁

@trombonefix
Copy link

Thanx @Alessandro-filho & @RatCaptain! You made my day!

After some issues trying to make package it now works with the older version. I had to install/update automake and make-pkg first.

I'm on fire with Linux since the end of the last year, started with Lubuntu, went over Linux Mint to Manjaro.

Each day I Iearn more about Linux and it makes fun to me!

@trombonefix
Copy link

Frio! E se eu estiver certo, você tinha a mesma coisa nos logs que eu, estou certo? ou é o mesmo que os logs do @trombonefix ?

To be honest, I don't even know how to look at the logs, lol
I will start a Linux course now!
But mine at the moment was resolved by going back.

I also didn't know do this and did it with this tutorial:
https://linuxhint.com/linux-journalctl-command/

@Alessandro-filho
Copy link

Alessandro-filho commented Feb 25, 2022

ooh

Frio! E se eu estiver certo, você tinha a mesma coisa nos logs que eu, estou certo? ou é o mesmo que os logs do @trombonefix ?

To be honest, I don't even know how to look at the logs, lol
I will start a Linux course now!
But mine at the moment was resolved by going back.

I also didn't know do this and did it with this tutorial: https://linuxhint.com/linux-journalctl-command/

ooh, thanks
but mine gives an error when running the log command
bash: /home/ley/.config/GitHub: File or folder does not exist

@trombonefix
Copy link

trombonefix commented Feb 25, 2022

Sorry, it was the wrong link:
https://www.geeksforgeeks.org/journalctl-command-in-linux-with-examples/

You have to open terminal and then sudo journalctl | grep github. This give you only the logs depending on GitHub.

@Alessandro-filho
Copy link

now it works, thanks

@Lunarequest
Copy link

Some folks have run into this issue on the flatpak(older versions work) this might be a regression

@shiftkey shiftkey added the dbus Bug reports related to dbus setup label Apr 3, 2022
@shiftkey
Copy link
Owner

shiftkey commented Apr 3, 2022

Apologies for being quiet on this one but after fixing a similar issue with #687 I'm looking at a comment like this with fresh eyes:

2022-02-24T13:20:36.423Z - warn: [ui] Unknown URL action: unknown - payload: {"name":"unknown","url":"--enable-crashpad"}

The root cause of #687 was that we weren't filtering out these parameters, which I wonder if is the same issue with the AppImage installer. It's been a while since I've used the AppImage version of the app but let's see if I can do the OAuth process with it on this machine and report back.

@shiftkey
Copy link
Owner

shiftkey commented Apr 3, 2022

After trying to poke at this some more both Firefox and Chromium have issues with passing the right arguments to the AppImage so that it will complete the authentication flow. Not sure when I'll be able to correct this, and I'd recommend using the deb or rpm packages if possible as those seem to integrate better with xdg-open.

@DioEgizio
Copy link

i can reproduce on void with the appimage

@cassidyjames
Copy link

I'm also seeing this on Endless OS running GitHub Desktop 3.0 from Flatpak. My browser is actually GNOME Web, and it gives me a similar "Unable to display this website" error, and even passing the URL from the URL bar into xdg-open in Terminal re-focuses the GitHub Desktop app, but it stays spinning waiting for authentication.

@AZHELLRGX
Copy link

AZHELLRGX commented Apr 30, 2022 via email

@AZHELLRGX
Copy link

AZHELLRGX commented Oct 11, 2022 via email

@Rudxain
Copy link

Rudxain commented Jul 10, 2023

I've tested 2.6.6 and 2.6.3 (both AppImages), but none work either

@AZHELLRGX
Copy link

AZHELLRGX commented Jul 10, 2023 via email

@shiftkey
Copy link
Owner

Closing this out due to inactivity, and the fact that I might have fixed this inadvertently a while ago.

Please open a fresh issue if you are still seeing this.

@shiftkey shiftkey closed this as not planned Won't fix, can't repro, duplicate, stale Dec 20, 2023
@AZHELLRGX
Copy link

AZHELLRGX commented Dec 20, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dbus Bug reports related to dbus setup unclear
Projects
No open projects
Development

No branches or pull requests