Instrument Python applications with structured logs, metrics, and traces. When something breaks in production, you need to answer "what, where, and why" without deploying new code.
Emit logs as JSON with consistent fields for production environments. Machine-readable logs enable powerful queries and alerts. For local development, consider human-readable formats.
Track latency, traffic, errors, and saturation for every service boundary.
Шаблоны наблюдения Python, включая структурированное ведение журналов, метрики и распределенную трассировку. Используйте при добавлении журналов, реализации сбора метрик, настройке трассировки или отладке производственных систем. Источник: wshobson/agents.