We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7a5563a commit 7515da8Copy full SHA for 7515da8
1 file changed
src/seclab_taskflow_agent/render_utils.py
@@ -5,16 +5,11 @@
5
import asyncio
6
from .path_utils import log_file_name
7
8
-logging.basicConfig(
9
- level=logging.DEBUG,
10
- format='%(asctime)s - %(levelname)s - %(message)s',
11
- filename=log_file_name('render_stdout.log'),
12
- filemode='a'
13
-)
14
-
15
async_output = {}
16
async_output_lock = asyncio.Lock()
17
+LOG_FILE = log_file_name('render_stdout.log')
+
18
async def flush_async_output(task_id: str):
19
async with async_output_lock:
20
if task_id not in async_output:
@@ -40,5 +35,6 @@ async def render_model_output(data: str,
40
35
data = "** 🤖✏️ Gathering output from async task ... please hold\n"
41
36
if data:
42
37
if log:
43
- logging.debug(data)
38
+ with open(LOG_FILE, 'a') as f:
39
+ f.write(data)
44
print(data, end="", flush=True)
0 commit comments