Skip to content

fix(cli): wire up the --debug flag to the log level - #1580

Closed
sanketpatel32 wants to merge 1 commit into
TagStudioDev:mainfrom
sanketpatel32:devin/fix-debug-flag
Closed

sanketpatel32 wants to merge 1 commit into
TagStudioDev:mainfrom
sanketpatel32:devin/fix-debug-flag

Conversation

@sanketpatel32

Copy link
Copy Markdown

Summary

Fixes #1249. The --debug CLI argument was parsed but never read, and with no logging configuration structlog emitted every level, so debug logs printed by default.

  • __main__.py now configures structlog with make_filtering_bound_logger: INFO by default, DEBUG when --debug is passed.
  • Verified structlog.make_filtering_bound_logger is available in the pinned structlog~=25.3.

Tasks Completed

  • Platforms Tested:
    • Windows x86
    • Windows ARM
    • macOS x86
    • macOS ARM
    • Linux x86
    • Linux ARM
  • Tested For:
    • Basic functionality (test suite + pre-commit hooks passing)
    • PyInstaller executable

The --debug argument was parsed but never read, and structlog ran
unfiltered so debug logs always printed. The log level is now INFO
by default and DEBUG when --debug is passed.

Fixes TagStudioDev#1249
@CyanVoxel CyanVoxel closed this Nov 23, 2026
@TrigamDev TrigamDev added the Type: Invalid This doesn't seem right label Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Type: Invalid This doesn't seem right

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: CLI 'debug' argument not implemented

3 participants