davehornik / sd-discord-rich_presence

Discord Rich Presence for AUTOMATIC1111's Stable Diffusion WebUI
GNU Affero General Public License v3.0
21 stars 3 forks source link

[BUG] Discord Rich Presence not working while current version of discord Desktop is running #14

Open Jeffpiatt2k4 opened 1 year ago

Jeffpiatt2k4 commented 1 year ago

SD console shows this output [Discord Rich Presence] Requirements already satisfied, skipping. [Discord Rich Presence] Only working on local instalation. And only w/ desktop Discord app. image Running Windows 11 22H2 image A1111version: [v1.4.1] python: 3.10.6   torch: 2.0.1+cu118     xformers: 0.0.20  •  gradio: 3.32.0  •  Discord version image

marduk191 commented 11 months ago

https://github.com/davehornik/sd-discord-rich_presence/pull/13/commits/9c6a74c4947555e07a27cee023e8f9a5d82cce01 should fix this

luni-moon commented 11 months ago

9c6a74c should fix this

Mine refuses to work still, using the beta branch... Here is my output:

[Discord Rich Presence]  Running Discord Rich Presence Extension, version 1.2.0
[Discord Rich Presence]  Bug reporting -> https://github.com/davehornik/sd-discord-rich_presence
[Discord Rich Presence]  'pypresence' module is installed - skipping.
*** Error executing callback ui_tabs_callback for H:\AI\stable-diffusion-webui\extensions\sd-discord-rich_presence\scripts\webui-rpc.py
    Traceback (most recent call last):
      File "H:\AI\stable-diffusion-webui\modules\script_callbacks.py", line 166, in ui_tabs_callback
        res += c.callback() or []
      File "H:\AI\stable-diffusion-webui\extensions\sd-discord-rich_presence\scripts\webui-rpc.py", line 144, in on_ui_tabs
        start_rpc()
      File "H:\AI\stable-diffusion-webui\extensions\sd-discord-rich_presence\scripts\webui-rpc.py", line 34, in start_rpc
        rpc.connect()
      File "H:\AI\stable-diffusion-webui\venv\lib\site-packages\pypresence\presence.py", line 43, in connect
        self.loop.run_until_complete(self.handshake())
      File "C:\Users\Lukas\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 646, in run_until_complete
        return future.result()
      File "H:\AI\stable-diffusion-webui\venv\lib\site-packages\pypresence\baseclient.py", line 116, in handshake
        self.sock_writer, _ = await asyncio.wait_for(self.loop.create_pipe_connection(lambda: reader_protocol, ipc_path), self.connection_timeout)
    AttributeError: '_WindowsSelectorEventLoop' object has no attribute 'create_pipe_connection'
luni-moon commented 11 months ago

Disregard that, I didn't see it was a PR

popa39 commented 8 months ago

9c6a74c should fix this

thanks!

marduk191 commented 8 months ago

9c6a74c should fix this

thanks!

no problem, it's not perfect but I stopped using auto for a long time and really didn't notice it, I'm guessing the op did as well. someone should be able to run with that patch and fix the rest pretty easily though lol.