vanchaxy opened a new issue, #52771:
URL: https://github.com/apache/airflow/issues/52771

   ### Description
   
   Change the log level for "[Variable not 
found](https://github.com/apache/airflow/blob/main/task-sdk/src/airflow/sdk/api/client.py#L318)"
 from error to debug when a default is provided.
   
   ### Use case/motivation
   
   I'm testing migration to Airflow 3.0.2 and have noticed a lot of errors in 
the logs. The problem is that Airflow logs errors when a variable is not found, 
even if a default is provided.
   
   In our use case, we have 100+ DAGs and use variables to configure schedules 
for them, so variables are read during DAG loading. This leads to significant 
error log spam that is picked up by Sentry. It's possible to work around this 
with custom logging filters, but I believe using the error log level is 
suboptimal and should be changed in Airflow core, especially considering 
`Variable.get` supports the "default" kwarg.
   
   ### Related issues
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to