refactor(bot): ⚰️ Remove dead code.
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
from multiprocessing import managers
|
from multiprocessing import managers
|
||||||
|
|
||||||
from datetime import datetime, timezone, timedelta
|
from datetime import datetime, timezone
|
||||||
|
|
||||||
|
|
||||||
def shard(
|
def shard(
|
||||||
@@ -27,19 +27,7 @@ def shard(
|
|||||||
bot.shutdown = shutdown
|
bot.shutdown = shutdown
|
||||||
bot.scheduled_shutdown = scheduled_shutdown
|
bot.scheduled_shutdown = scheduled_shutdown
|
||||||
|
|
||||||
try:
|
|
||||||
# Skip uvloop initialization, it stops tasks from running for some reason.
|
|
||||||
raise ImportError()
|
|
||||||
|
|
||||||
import uvloop # pylint: disable=import-error
|
|
||||||
|
|
||||||
bot.loop = uvloop.new_event_loop()
|
|
||||||
print(f"Running shard {shard_id} with uvloop.")
|
|
||||||
|
|
||||||
except ImportError:
|
|
||||||
print(f"Running shard {shard_id} with default loop.")
|
print(f"Running shard {shard_id} with default loop.")
|
||||||
|
|
||||||
finally:
|
|
||||||
bot.run(config.TOKEN)
|
bot.run(config.TOKEN)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user