logging references
This commit is contained in:
@@ -18,6 +18,8 @@ Use this skill to produce idiomatic Python logging guidance or a small logging s
|
||||
|
||||
Load references only when needed:
|
||||
- Python logging overview, library guidance, handlers, and dictConfig schema: [Python logging references](./references/python-logging-docs.md)
|
||||
- Minimal network logging example with a receiver and queue-backed client: [Network logging minimal example](./references/network-logging-minimal-example.md)
|
||||
- HTTP JSON logging example with `httpx` and a queue-backed client: [HTTPX logging handler example](./references/httpx-logging-handler-example.md)
|
||||
|
||||
## When to Use
|
||||
|
||||
@@ -127,6 +129,7 @@ def run(count: int) -> None:
|
||||
- If structured logs are required: keep the same logger and handler topology, but switch formatter output to JSON or a structured formatter.
|
||||
- If console and file output are needed: add one file or rotating-file handler and attach it centrally.
|
||||
- If multiple processes write to one file: use a queue/listener or process-safe collection path rather than opening the same file independently in each process.
|
||||
- If logs must cross a network: send records to a receiver or collector from a queue-backed handler, keep the receiver responsible for final destinations, and avoid exposing unauthenticated logging ports.
|
||||
- If a framework logger is noisy: add a named logger override with a level and leave unrelated logger propagation alone.
|
||||
|
||||
## Completion Checks
|
||||
|
||||
Reference in New Issue
Block a user