Skip to content

Discord Rich Presence is either very delayed or completely incorrect. #1910

@officialnochill

Description

@officialnochill

Desktop

  • OS: CachyOS
  • OS version: Rolling
  • Tauon Version: v8.2.2
  • Installation method: AUR

Describe the bug

Discord Rich Presence is either very delayed or completely incorrect, sometimes displaying a completely different song (usually hard stuck to the first song of the session, not updating correctly on pause or next song / previous song) or is very delayed.

To Reproduce

Steps to reproduce the behavior:

Play a song, check your discord activity with Rich Presence connected, notice that when you press next song on your keyboard or pause it quickly is completely different.

Looking at the logs, it appears that it fails to connect to discord... sometimes.

Expected behavior

The correct song to show up on discord.

Screenshots/Videos

Image

Tauon log

Logfiles
04:41:10 [DEBUG] tag: XResolution (282) - type: rational (5) Tag Location: 34 - Data Location: 98 - value: b"\x00\n\xfc\x80\x00\x00'\x10"
04:41:10 [DEBUG] tag: YResolution (283) - type: rational (5) Tag Location: 46 - Data Location: 106 - value: b"\x00\n\xfc\x80\x00\x00'\x10"
04:41:10 [DEBUG] tag: ResolutionUnit (296) - type: short (3) - value: b'\x00\x02'
04:41:10 [DEBUG] tag: Software (305) - type: string (2) Tag Location: 70 - Data Location: 114 - value: b'Adobe Photoshop 21.1 (Windows)\x00'
04:41:10 [DEBUG] tag: DateTime (306) - type: string (2) Tag Location: 82 - Data Location: 145 - value: b'2020:05:01 12:17:06\x00'
04:41:10 [DEBUG] tag: ExifIFD (34665) - type: long (4) - value: b'\x00\x00\x00\xa8'
04:41:11 [ ERROR ] Error connecting to Discord - is Discord running?
Traceback (most recent call last):
  File "/usr/lib/python3.13/site-packages/tauon/t_modules/t_main.py", line 11863, in discord_loop
    RPC.update(
    ~~~~~~~~~~^
    	activity_type = ActivityType.LISTENING,
     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ...<6 lines>...
    	large_image=large_image,
     ^^^^^^^^^^^^^^^^^^^^^^^^
    	small_image=small_image)
     ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/lynxpresence/presence.py", line 36, in update
    return self.loop.run_until_complete(self.read_output())
           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/asyncio/base_events.py", line 725, in run_until_complete
    return future.result()
           ~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/lynxpresence/baseclient.py", line 87, in read_output
    raise ServerError(payload["data"]["message"])
lynxpresence.exceptions.ServerError: Child "activity" fails because child "details" fails because "details" is not allowed to be empty
04:41:13 [DEBUG] Using selector: EpollSelector
04:41:13 [DEBUG] Using selector: EpollSelector
04:41:13 [DEBUG] Using selector: EpollSelector
04:41:13 [WARNING] /usr/lib/python3.13/site-packages/lynxpresence/utils.py:52: ResourceWarning: unclosed scandir iterator <posix.ScandirIterator object at 0x7f693efc3830>
  return entry.path

04:41:13 [DEBUG] Position set by show playing
04:41:13 [ INFO  ] Open - requested start was 0.0 (0)
04:41:13 [ INFO  ] Extension: flac
04:41:13 [ INFO  ]  -> Lion Garden
04:41:13 [ INFO  ]  --- length: 26.493
04:41:13 [ INFO  ]  --- position: 2.349
04:41:13 [ INFO  ]  --- We are 24.144 from end
04:41:13 [ INFO  ] Transition jump
04:41:13 [ INFO  ] Discord RPC connection successful.
04:41:22 [DEBUG] Message: Lines copied to clipboard  
04:42:21 [DEBUG] Position set by show playing
04:42:21 [ INFO  ] Open - requested start was 0.0 (0)
04:42:21 [ INFO  ] Extension: flac
04:42:21 [ INFO  ] Lion Garden -> 
04:42:21 [ INFO  ]  --- length: 219.026
04:42:21 [ INFO  ]  --- position: 61.846
04:42:21 [ INFO  ]  --- We are 157.18 from end
04:42:21 [ INFO  ] Transition jump
04:42:23 [ ERROR ] Error connecting to Discord - is Discord running?
Traceback (most recent call last):
  File "/usr/lib/python3.13/site-packages/tauon/t_modules/t_main.py", line 11863, in discord_loop
    RPC.update(
    ~~~~~~~~~~^
    	activity_type = ActivityType.LISTENING,
     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ...<6 lines>...
    	large_image=large_image,
     ^^^^^^^^^^^^^^^^^^^^^^^^
    	small_image=small_image)
     ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/lynxpresence/presence.py", line 36, in update
    return self.loop.run_until_complete(self.read_output())
           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/asyncio/base_events.py", line 725, in run_until_complete
    return future.result()
           ~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/lynxpresence/baseclient.py", line 87, in read_output
    raise ServerError(payload["data"]["message"])
lynxpresence.exceptions.ServerError: Child "activity" fails because child "details" fails because "details" is not allowed to be empty
04:42:40 [DEBUG] Using selector: EpollSelector
04:42:40 [DEBUG] Position set by show playing
04:42:40 [DEBUG] Using selector: EpollSelector
04:42:40 [DEBUG] Using selector: EpollSelector
04:42:40 [WARNING] /usr/lib/python3.13/site-packages/lynxpresence/utils.py:52: ResourceWarning: unclosed scandir iterator <posix.ScandirIterator object at 0x7f693efb2e30>
  return entry.path

04:42:40 [ INFO  ] Discord RPC connection successful.
04:42:40 [ INFO  ] Open - requested start was 0.0 (0)
04:42:40 [ INFO  ] Extension: flac
04:42:40 [ INFO  ]  -> Opulence
04:42:40 [ INFO  ]  --- length: 26.493
04:42:40 [ INFO  ]  --- position: 17.78
04:42:40 [ INFO  ]  --- We are 8.712999999999997 from end
04:42:40 [ INFO  ] Transition jump
04:42:45 [DEBUG] Starting new HTTPS connection (1): coverartarchive.org:443
04:42:45 [DEBUG] https://coverartarchive.org:443 "GET /release-group/143f0205-d68c-40da-af4e-2b285c5158a4 HTTP/1.1" 307 87
04:42:45 [DEBUG] Starting new HTTPS connection (1): archive.org:443
04:42:47 [DEBUG] https://archive.org:443 "GET /download/mbid-6dcbf11c-e05c-45af-9cba-8bd4dae82600/index.json HTTP/1.1" 302 None
04:42:47 [DEBUG] Starting new HTTPS connection (1): ia801803.us.archive.org:443
04:42:48 [DEBUG] https://ia801803.us.archive.org:443 "GET /25/items/mbid-6dcbf11c-e05c-45af-9cba-8bd4dae82600/index.json HTTP/1.1" 200 856
04:42:48 [ INFO  ] got mb image url for discord

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions