-
Notifications
You must be signed in to change notification settings - Fork 13
Open
Labels
Description
Bug Report: --log-level DEBUG not working after logging initialization
Bug Description
When running CLI commands with --log-level DEBUG, the debug logs are not displayed if logging has already been initialized. The reconfigure() method only updates the file destination but ignores the log level parameter.
To Reproduce
-
Run any CLI command first (logging gets initialized):
qdrant-loader config --workspace . -
Run another command with
--log-level DEBUG:qdrant-loader ingest --workspace . --log-level DEBUG -
Observe that DEBUG level logs are not shown
Expected Behavior
- Debug logs should be displayed when
--log-level DEBUGis specified - Log level should be reconfigurable at runtime
Expected output:
DEBUG: Starting ingestion...
DEBUG: Loading config from...
INFO: Ingestion completed
Actual Behavior
- Debug logs are not shown
- Log level remains at the initial value (INFO)
Actual output:
INFO: Ingestion completed
(no debug logs shown)
Environment
- OS: Linux (WSL2)
- Python version: 3.12
- QDrant Loader version: 0.7.3
Root Cause Analysis
In packages/qdrant-loader-core/src/qdrant_loader_core/logging.py:360, the reconfigure() method only accepts file parameter and ignores log level:
# Current implementation
def reconfigure(file: Optional[str] = None):
# Only handles file, ignores level
...Proposed Solution
Update reconfigure() to accept and apply level parameter, then update all CLI commands to pass level=log_level.
Affected Files
packages/qdrant-loader-core/src/qdrant_loader_core/logging.pypackages/qdrant-loader/src/qdrant_loader/cli/commands/config.pypackages/qdrant-loader/src/qdrant_loader/cli/commands/config_cmd.pypackages/qdrant-loader/src/qdrant_loader/cli/commands/ingest_cmd.pypackages/qdrant-loader/src/qdrant_loader/cli/commands/init_cmd.py
Labels
bug, cli, logging, bug