potiuk commented on code in PR #30994:
URL: https://github.com/apache/airflow/pull/30994#discussion_r1182957639


##########
dev/provider_packages/prepare_provider_packages.py:
##########
@@ -1318,6 +1327,25 @@ def update_release_notes(
     return True
 
 
+def update_min_airflow_version(provider_package_id: str, version_suffix: str):
+    provider_details = get_provider_details(provider_package_id)
+    provider_info = get_provider_info_from_provider_yaml(provider_package_id)
+    jinja_context = get_provider_jinja_context(
+        provider_info=provider_info,
+        provider_details=provider_details,
+        current_release_version=provider_details.versions[0],
+        version_suffix=version_suffix,
+    )
+    generate_init_py_file_for_provider(
+        context=jinja_context,
+        target_path=provider_details.source_provider_package_path,
+    )
+    if not jinja_context["PREINSTALLED_PROVIDER"]:
+        replace_min_airflow_version_in_provider_yaml(
+            context=jinja_context, 
target_path=provider_details.source_provider_package_path
+        )

Review Comment:
   ```python
       min_airflow_version = MIN_AIRFLOW_VERSION
       if 
MIN_AIRFLOW_VERSION_EXCEPTIONS.get(provider_details.provider_package_id):
           min_airflow_version = 
MIN_AIRFLOW_VERSION_EXCEPTIONS[provider_details.provider_package_id]
   ```



-- 
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