Skip to content

Commit

Permalink
remove global max_instances
Browse files Browse the repository at this point in the history
  • Loading branch information
BennyThink committed Dec 30, 2023
1 parent 882b313 commit fb2f448
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ytdlbot/database.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ def __init__(self):
self.con = pymysql.connect(
host=MYSQL_HOST, user=MYSQL_USER, passwd=MYSQL_PASS, db="ytdl", charset="utf8mb4"
)
self.con.ping(reconnect = True)
self.con.ping(reconnect=True)
except Exception:
logging.warning("MySQL connection failed, using fake mysql instead.")
self.con = FakeMySQL()
Expand Down
2 changes: 1 addition & 1 deletion ytdlbot/ytdl_bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -583,7 +583,7 @@ def track_memory():
MySQL()
tr = tracker.SummaryTracker()
TRX_SIGNAL.connect(trx_notify)
scheduler = BackgroundScheduler(timezone="Europe/London", job_defaults={"max_instances": 6})
scheduler = BackgroundScheduler(timezone="Europe/London")
scheduler.add_job(auto_restart, "interval", seconds=600)
scheduler.add_job(clean_tempfile, "interval", seconds=120)
if not IS_BACKUP_BOT:
Expand Down

0 comments on commit fb2f448

Please sign in to comment.