potiuk opened a new pull request, #30994: URL: https://github.com/apache/airflow/pull/30994
This change adds full automation for keeping and updating min airflow version for all community providers. It makes sure that: * all non-preinstalled providers have min-airflow-version set properly * all providers (including the preinstalled ones) additionally perform a runtime check on whether correct version of Airflow is installed. * allows for exceptional cases for some providers to be set * all providers have `version` added and exported in their `__init__.py` Usually just setting the airflow version in requirements should be enough, but since we have to install runtime check for preinstalled providers, it's easier to add the runtime check for all providers, and it will be additional verification that airflow version is properly set. Additionally, we can export correct version in the automatically generated `__init__.py` for all providers. The pre-installed providers cannot have explicit minimum airflow version specified as requirement, because this would create a dependency cycle with Airflow, and while such dependency cycle is fine for `pip`, other tools that analyse dependencies get confused and produce errors, claiming there cannot be dependenc cycles in the dependency tree (which is not generally a hard requirement, package dependency graph does not have to be DAG and it can contain cycles). This is why we have to add runtime check in the preinstalled providers to fail when they are installed with older Airflow versions than the ones that are supported by our policy. This PR automates maintenance of all the versions involved during prepearation of release documentation - it has been somewhat manual procedure so far, because it was only set in provider.yaml, but since now we set it in several places, it requires automation and single source of truth (which is prepare_provider_packages.py script that is used for preparation of provider documenation and packages. <!-- Thank you for contributing! Please make sure that your code changes are covered with tests. And in case of new features or big changes remember to adjust the documentation. Feel free to ping committers for the review! In case of an existing issue, reference it using one of the following: closes: #ISSUE related: #ISSUE How to write a good git commit message: http://chris.beams.io/posts/git-commit/ --> --- **^ Add meaningful description above** Read the **[Pull Request Guidelines](https://github.com/apache/airflow/blob/main/CONTRIBUTING.rst#pull-request-guidelines)** for more information. In case of fundamental code changes, an Airflow Improvement Proposal ([AIP](https://cwiki.apache.org/confluence/display/AIRFLOW/Airflow+Improvement+Proposals)) is needed. In case of a new dependency, check compliance with the [ASF 3rd Party License Policy](https://www.apache.org/legal/resolved.html#category-x). In case of backwards incompatible changes please leave a note in a newsfragment file, named `{pr_number}.significant.rst` or `{issue_number}.significant.rst`, in [newsfragments](https://github.com/apache/airflow/tree/main/newsfragments). -- 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]
