potiuk commented on pull request #12466:
URL: https://github.com/apache/airflow/pull/12466#issuecomment-735375753


   > Therefore that is not a cyclic import.
   
   Of course not cyclic import. Cyclic imports are detected by python parser so 
there is no point static-checking them. Pylint detects cyclic dependencies 
between modules instead.
   
   It's a cyclic dependency between modules, not a cyclic import (just to 
reiterate what I keep on repeating). 
   
   Those are different things and this one is easy (and natural) to solve. If 
two modules are using a common function, it's better to extract it to a 
separate module, rather than having one module depended on the other where the 
dependency could be reverted.
   
   Both providers_manager and plugins_manager are at the same "logical" level, 
so there is no reason why providers manager should import anything from 
plugins_manager. Why not plugins manager importing the same function from 
providers manager ? 
   
   So extracting it to common module makes perfect sense and is "cleaner" 
architecture - and this is what pylint complains about.
   
   


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