Skip to content

Replace print() with structured logging in request/endpoint handlers#60

Merged
lbedogni merged 1 commit into
mainfrom
fix/sciot-012-structured-logging-request-handler
Jul 13, 2026
Merged

Replace print() with structured logging in request/endpoint handlers#60
lbedogni merged 1 commit into
mainfrom
fix/sciot-012-structured-logging-request-handler

Conversation

@ff225

@ff225 ff225 commented Jul 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Replaces remaining print() calls in request_handler.py and the http_server.py inference endpoint with the project's structured logger (info for status/registration messages, warning/error for failures).
  • These messages previously bypassed log levels, formatting, and file handlers configured in server/logger/log.py.

Test plan

  • Added tests/unit/test_no_print_statements.py, a source-scan regression test asserting no print( calls remain in these two files.
  • uv run pytest tests/unit -m "not external_server and not model_artifact" passes (126 passed, 1 skipped).

Closes #12

request_handler.py and the http_server.py inference endpoint still used
print() for server status/error output instead of the project's
structured logger, so those messages bypassed log levels and handlers.

Closes #12
@lbedogni lbedogni merged commit 24d077c into main Jul 13, 2026
3 checks passed
@lbedogni lbedogni deleted the fix/sciot-012-structured-logging-request-handler branch July 13, 2026 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Replace print statements with structured logging

2 participants