Skip to content

Remove rich.print debug output from search queries #22

Closed

Description

@matthewberry

app/db/queries.py prints to stdout through rich on every search request:

  • queries.py:27: rich.print(f"Processing column: {column} with values: {values}"), once per string filter column (five lines per request, even when the filter is unset)
  • queries.py:174: rich.print(f"{query=}"), the full SQL of every data query

These are synchronous stdout writes in async request handlers, and they bypass loguru, which the rest of the app uses. They also log the filter values users send. PR #20 makes the CSV path run build_conditions twice per request, so it prints twice as many lines.

Suggested fix: remove them, or change them to logger.debug(...) if the SQL is useful when debugging.

Found while reviewing #20. Not covered by #21, which removes only the DB-settings prints in app/db/database.py.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions