File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -385,11 +385,23 @@ def log_uncaught_exceptions(
385
385
) # default log to project root
386
386
openhands_logger .debug (f'Logging to file in: { LOG_DIR } ' )
387
387
388
- # Exclude LiteLLM from logging output
388
+ # Exclude LiteLLM from logging output as it can leak keys
389
389
logging .getLogger ('LiteLLM' ).disabled = True
390
390
logging .getLogger ('LiteLLM Router' ).disabled = True
391
391
logging .getLogger ('LiteLLM Proxy' ).disabled = True
392
392
393
+ # Exclude loquacious loggers
394
+ LOQUACIOUS_LOGGERS = [
395
+ 'engineio' ,
396
+ 'engineio.server' ,
397
+ 'socketio' ,
398
+ 'socketio.client' ,
399
+ 'socketio.server' ,
400
+ ]
401
+
402
+ for logger_name in LOQUACIOUS_LOGGERS :
403
+ logging .getLogger (logger_name ).setLevel ('WARNING' )
404
+
393
405
394
406
class LlmFileHandler (logging .FileHandler ):
395
407
"""LLM prompt and response logging."""
You can’t perform that action at this time.
0 commit comments