Keith Smith
10/24/2024, 8:17 PMMarvin
10/24/2024, 8:17 PMKeith Smith
10/24/2024, 8:17 PMMarvin
10/24/2024, 8:18 PMprefect config set PREFECT_LOGGING_LEVEL=DEBUG
2. Using Environment Variables:
Alternatively, you can set the logging level using environment variables. You can do this by exporting the variable as follows:
export PREFECT_LOGGING_LEVEL=DEBUG
These settings ensure that the worker logs additional details, helping you troubleshoot any issues with more granularity. Keep in mind that the "DEBUG" level will produce a high volume of logs, so use it cautiously.
For more information on logging customization, you can refer to the following resources:
- Troubleshoot Cloud
- Develop: LoggingNate
10/24/2024, 8:18 PMKeith Smith
10/24/2024, 8:19 PMNate
10/24/2024, 8:22 PM» PREFECT_LOGGING_LEVEL=DEBUG prefect worker start -p local
15:21:31.051 | DEBUG | prefect.profiles - Using profile 'bleeding'
15:21:31.115 | DEBUG | prefect.client - Connecting to API at <http://localhost:4200/api/>
...
but if you're starting some ACI service that runs your worker, that might look a bit differentNate
10/24/2024, 8:23 PMexport PREFECT_LOGGING_LEVEL=DEBUG
on whatever machine is running your workerNate
10/24/2024, 8:25 PM» docker run --rm prefecthq/prefect:3.0.4-python3.12 -- echo "PREFECT_LOGGING_LEVEL=DEBUG" > .env && prefect worker start -p local
15:24:29.453 | DEBUG | prefect.profiles - Using profile 'bleeding'
15:24:29.541 | DEBUG | prefect.client - Connecting to API at <http://localhost:4200/api/>
you can even just put stuff in an .env
wherever you start your worker if that ends up being usefulKeith Smith
10/24/2024, 8:28 PMNate
10/24/2024, 8:29 PMKeith Smith
10/24/2024, 8:33 PMNate
10/24/2024, 8:34 PMprefect worker start
you'd kill / restart that processKeith Smith
10/24/2024, 8:41 PMNate
10/24/2024, 8:42 PM