Switched to docker compose and wasted hours trying to have standalone firefox

This commit is contained in:
Remy Moll
2022-05-29 18:29:31 +02:00
parent 878a1dff5d
commit 54760abee4
13 changed files with 154 additions and 42 deletions

View File

@@ -3,7 +3,6 @@ import configuration
import requests
import os
import time
import sys
from threading import Thread
from slack_sdk.errors import SlackApiError
@@ -30,10 +29,10 @@ def init(client) -> None:
t = Thread(target = fetch_missed_channel_reactions) # threaded, runs in background (usually takes a long time)
t.start()
if "reducedfetch" in sys.argv:
logger.warning("Only fetching empty threads for bot messages because of argument 'reducedfetch'")
if os.getenv("REDUCEDFETCH", "false") == "true":
logger.warning("Only fetching empty threads for bot messages because 'REDUCEDFETCH=true'")
fetch_missed_thread_messages(reduced=True)
else: # perform these two asyncronously
else: # perform both asyncronously
fetch_missed_thread_messages()