gsd 1 month ago
parent
commit
03b6734820
  1. 2
      other_ext/register.py
  2. 2
      ws.py

2
other_ext/register.py

@ -18,7 +18,7 @@ class Extension:
if not os.getenv("REGISTER_ENABLED", None): return None if not os.getenv("REGISTER_ENABLED", None): return None
self.core = core self.core = core
@core.tree.command(name = "register", description = "Привязать дискорд к стиму") @core.tree.command(name = "register", description = "Привязать дискорд к стиму")
@discord.app_commands.describe(profile=core.ANY_INPUT) @discord.app_commands.describe()
async def register( async def register(
interaction: discord.Interaction interaction: discord.Interaction
): ):

2
ws.py

@ -3,6 +3,7 @@ from threading import Thread
from json import dumps from json import dumps
from time import sleep from time import sleep
import os import os
import traceback
START_AFTER_CONNECT = None START_AFTER_CONNECT = None
SERVICE_NAME = None SERVICE_NAME = None
@ -40,6 +41,7 @@ class WS:
@staticmethod @staticmethod
def on_close(ws_self, status_code, msg): def on_close(ws_self, status_code, msg):
traceback.print_exc()
print(f"WS Close, code:{status_code}, msg: {msg}") print(f"WS Close, code:{status_code}, msg: {msg}")
sys.exit(0) sys.exit(0)

Loading…
Cancel
Save