Jovan Sakovic01/28/2022, 6:41 PM
) • pass these logger object from function to function to finally get to the one that is running on threads ◦
logger = prefect.context.get("logger")
extract_thread = Thread(target=extract_messages, name=f"Extractor #1", args=(extract_queue, load_queue, logger))
def extract_messages(extract_queue, load_queue, logger): while True: request = extract_queue.get() if request == None: extract_queue.put(None) break request["extracted_at"] = datetime.now().strftime("%s") messages_request = api_request(request, logger) ## This never logs in the UI <http://logger.info|logger.info>("Queueing messages. ")
Jovan Sakovic01/28/2022, 7:11 PM
? If I raise an exception (
)within that function nothing happens with the Flow. Would that also be taken care of if I implement the LocalDaskExecutor?