bitfocus / companion-module-discord-api

MIT License
5 stars 2 forks source link

Login err: {} #26

Closed PashaKopka closed 6 months ago

PashaKopka commented 6 months ago

Describe the bug I can't activate connection. Discord instance is running on machine, I created new application and pasted Client ID and Client Secret in configuration. I added "http://localhost" to the discord application settings.

To Reproduce

  1. Open discord on your machine
  2. Add connection to "Connections" tab in Companion
  3. Create discord application and follow the installing steps
  4. Open the Companion tab "Log" and see the error: "24.01.29 20:18:20 Instance/Wrapper/discord: Login err: {}"

Expected behaviour Connection will connect to discord and start working

Screenshots image

System (please complete the following information):

Additional context ...

thedist commented 6 months ago

Just to check, this is the proper release of Discord, not a 3rd party client or beta? Discord is running on the same machine as Companion? The user account on Discord is the same user account that created the Discord app?

PashaKopka commented 6 months ago
  1. I don't clearly know if it is a proper release of Discord, because it's running on Linux (Fedora 39). It is downloaded from flathub: link. There is a verification mark here, so I think it's official release.
  2. Yes, Discord is running on the same machine as Companion.
  3. Yes, the user account is the same

Is it necessary to specify port in discord application settings? The instruction says: "In the Redirects section, add http://localhost as a redirect URL", localhost but nothing about the port

thedist commented 6 months ago

Ah yeah, unfortunately Flatpak Discord will have issues as it's not a standard Discord release, it's made by 3rd parties and it wraps Discord in a sandbox which by default prevents external applications such as Companion being able to connect to the client.

Looking at their Github they do have a guide which may help, https://github.com/flathub/com.discordapp.Discord/wiki/Rich-Precense-(discord-rpc) but I don't use Flatpack Discord, I have no way to test it, and it's a non-standard Discord install so I can't easily offer any support to get it to work if that guide they have doesn't help.

PashaKopka commented 6 months ago

Yeah. It works for me. Thank you