You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "jjavieralonso (via GitHub)" <gi...@apache.org> on 2025/01/22 04:14:05 UTC
[I] Import Future Annotations in Virtual Environment Jinja Template Causes Errors [airflow]
jjavieralonso opened a new issue, #45900:
URL: https://github.com/apache/airflow/issues/45900
### Apache Airflow version
2.10.4
### If "Other Airflow 2 version" selected, which one?
_No response_
### What happened?
When using the python_virtualenv_script.jinja2 template in Apache Airflow, the absence of from __future__ import annotations caused errors in tasks with type annotations.
### What you think should happen instead?
The template should include from __future__ import annotations by default to support forward references in type annotations, ensuring compatibility and preventing errors. The template did not include the necessary import statement for future annotations, leading to type errors when annotations were used.
### How to reproduce
1. Create a task using the virtual environment decorator with type annotations in Airflow.
2. Run the task and observe the type errors due to missing from __future__ import annotations.
### Operating System
Windows 10
### Versions of Apache Airflow Providers
_No response_
### Deployment
Other 3rd-party Helm chart
### Deployment details
_No response_
### Anything else?
_No response_
### Are you willing to submit 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: commits-unsubscribe@airflow.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Import Future Annotations in Virtual Environment Jinja Template Causes Errors [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on issue #45900:
URL: https://github.com/apache/airflow/issues/45900#issuecomment-2606510414
Your reports are AI spam and create a lot of effort for maintainers.
I am closing the reports and blocking you. If you wish to get unblocked explain here:
1) how you generated those reports
2) prove you are human not bot
3) explain why are you doing it?
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Import Future Annotations in Virtual Environment Jinja Template Causes Errors [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk closed issue #45900: Import Future Annotations in Virtual Environment Jinja Template Causes Errors
URL: https://github.com/apache/airflow/issues/45900
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org