turbaszek commented on a change in pull request #14400:
URL: https://github.com/apache/airflow/pull/14400#discussion_r581362079



##########
File path: airflow/upgrade/rules/fix_conf_not_importable_from_airflow.py
##########
@@ -0,0 +1,29 @@
+
+from airflow.upgrade.rules.base_rule import BaseRule
+
+print(BaseRule)
+
+<<<<<<< HEAD
+
+class ConfImportFromAirflow(BaseRule):
+    """
+      ConfImportFromAirflow class to ensure proper import of conf from to work 
in Airflow 2.0
+      """
+    title = "Properly import conf from Airflow"
+    description = """\
+    In Airflow-2.0, it's not possible to import conf from airflow by using 
\'import conf from airflow\'
+    To ensure your code works in Airflow 2.0, you should use \'from 
airflow.Configuration import conf \'

Review comment:
       ```suggestion
       In Airflow-2.0, it's not possible to import `conf` from airflow by using 
`import conf from airflow`
       To ensure your code works in Airflow 2.0, you should use `from 
airflow.configuration import conf`.
   ```




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

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


Reply via email to