-
Notifications
You must be signed in to change notification settings - Fork 14.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add better diagnostics when provider.yaml check fails #37322
Add better diagnostics when provider.yaml check fails #37322
Conversation
@potiuk , Can you please confirm if this check only runs when there is a change in the If so, can we try to actually pass If not, would adding this help? I can look into this. |
No - we do not want to do it automatically, because running it takes a long time and it takes a lot of time and networking, so you should not really run it automatically when provider.yaml changes, because the fact that it changes, does not mean that you HAVE TO do it. In many situations, running pre-commits will be fine even if you don't run it, and it's fine, because when you have slow network, develop while in a plane etc, you don't want to pull 700 MB of data. The whole image rebuilding is designed around it - it should be "eventually consistent" - you are gently guided to rebuild the image, but you should not be forced to run the rebuild, because you might not want to do it just now. And adding new providers/modifying dependencies is generallly very rare event that we should not optimize for. What you experience might seam common, but there is a very low percentage of PRs that add or modify dependencies or change provider.yaml file (and even less that result in absolute need or rebuilding the image). This is explained in detail in the two ADRs (Architecture Decision Records): ADR4 where it is explained why we chose docker container as "common" environment and ADR12 - where the mechanism of eventual consistency and asking the user for confirmation is explained. |
Also it's not the case. In CI we always run "all" pre-commits. Pre-comit has two modes, one local (when it only run pre-commits that are related to locally modified files), and one usually used in ci where In CI in case dependencies were modified, we run And again - this is because running |
This makes sense and I agree. And, Thank you so much for such a detailed response. |
(cherry picked from commit 5ee75fb)
(cherry picked from commit 5ee75fb)
^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
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.