JustTemmie / steam-presence

A script that takes the game you're playing on steam and displays it on discord
MIT License
246 stars 18 forks source link

Not working with Armcord #68

Open x3ell opened 2 months ago

x3ell commented 2 months ago

Not working with Armcord

[Aug 28 2024 - 22:10:00] found game Inscryption played by ...
[Aug 28 2024 - 22:10:02] steam app ID 1092790 found for Inscryption
[Aug 28 2024 - 22:10:02] game changed, updating to 'Inscryption'
[Aug 28 2024 - 22:10:02] fetching the Discord game ID for Inscryption
[Aug 28 2024 - 22:10:03] found the discord game ID for inscryption
[Aug 28 2024 - 22:10:03] fetching icon for Inscryption
[Aug 28 2024 - 22:10:03] no image found in cache
[Aug 28 2024 - 22:10:03] getting icon from Discord
[Aug 28 2024 - 22:10:03] successfully found Discord icon for Inscryption
[Aug 28 2024 - 22:10:03] creating new rich presence object for Inscryption
Traceback (most recent call last):
  File "/home/.../steam-presence/main.py", line 1205, in <module>
    main()
  File "/home/.../steam-presence/main.py", line 1186, in main
    RPC.connect()
  File "/home/.../.local/lib/python3.10/site-packages/pypresence/presence.py", line 43, in connect
    self.loop.run_until_complete(self.handshake())
  File "/usr/lib/python3.10/asyncio/base_events.py", line 649, in run_until_complete
    return future.result()
  File "/home/.../.local/lib/python3.10/site-packages/pypresence/baseclient.py", line 108, in handshake
    raise DiscordNotFound
pypresence.exceptions.DiscordNotFound: Could not find Discord installed and running on this machine.
~/steam-presence$ 
JustTemmie commented 2 months ago

i find this quite weird, i use vesktop and that works - i believe they have the same arRPC implementation but i might be wrong

Abro61209 commented 2 months ago

So just ran into this issue as well.

I had vesktop installed as a FLATPAK. The installer works just fine, didn't return any errors, but my activity on steam was still blank.

Flatpaks are designed to have their own sandbox that's cut off from the rest of your system, to prevent the application from having unwanted access to critical directories. You can try flatseal to try and grant it more permissions, but it probably still wouldn't have worked anyway due to the nature of how flatpaks are designed, so I didn't bother.

I just built vesktop from source and threw the install folder in my /usr/local/bin, and binned the executable to my desktop.

TL;DR: Due to how flatpaks are designed, it most likely can't see the steam-presence service as its sandboxed and blocked off from the rest of your system. Use Discord/Vesktop as an appimage, or build it from source. Problem solved.

For the project dev: really nifty program btw! I like how when you click on what I'm playing, even on vanilla discord (desktop app only), I get all the info about the game! Super cool! Thanks for your work on this!

Edit 2: haha jk, the clicking the game and it showing all the info just seems like a new thing discord implemented

x3ell commented 1 month ago

Thanks! I will test non flatpak version and tell if it worked for me