Load variables from .env file into current environment
Load an .env file into the environment prior to running something which requires the environment variables:
Load an .env file into the environment prior to running something which requires the environment variables:
When using Datadog for monitoring, Datadog will only record a trace if there is an incoming request.
If there is no incoming request, such as if a cronjob is running, then Datadog will not record a trace and you might not be alerted by an error.
To solve this, you can use the ddtrace-py library and create a custom trace/span whenever tag and tag a span with exception information. This will effectively make it possible to track errors in APM error tracking.