We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b520df4 + ccab15d commit bc3bc3fCopy full SHA for bc3bc3f
3 files changed
.gitignore
@@ -1,4 +1,3 @@
1
-*.log
2
.direnv
3
.envrc
4
@@ -14,6 +13,9 @@ __pycache__/
14
13
# C extensions
15
*.so
16
+# Logs directory
17
+logs/
18
+
19
# Distribution / packaging
20
.Python
21
build/
logs/ABOUT
src/seclab_taskflow_agent/__main__.py
@@ -38,8 +38,10 @@
38
39
# only model output or help message should go to stdout, everything else goes to log
40
logging.getLogger('').setLevel(logging.NOTSET)
41
+log_dir = pathlib.Path("logs")
42
+log_dir.mkdir(parents=True, exist_ok=True)
43
log_file_handler = RotatingFileHandler(
- 'logs/task_agent.log',
44
+ log_dir.joinpath('task_agent.log'),
45
maxBytes=1024*1024*10,
46
backupCount=10)
47
log_file_handler.setLevel(os.getenv('TASK_AGENT_LOGLEVEL', default='DEBUG'))
0 commit comments