potiuk commented on issue #7421: [AIRFLOW-XXXX] Speed up mypy runs.
URL: https://github.com/apache/airflow/pull/7421#issuecomment-586470454
 
 
   > Could be. Would be interesting to see if mypy also chases down "delayed" 
imports (i.e. ones inside functions) at which point there's only so much we can 
do. But anyway, mypy time is relatively tiny in comparison to pylint :(
   
   Loking how mypy works - I think it won't help. What would help though is 
moving the stuff to sub-packages of airflow and removing them from airflow. I 
think this was a problem we could potentially fix in 2.0. Models should be in 
airflow.models, exceptions should be in airlflow.exceptions and we should only 
import what is explictly imported. We should never have loading of all objects 
in airflow.__init__,py -> this is really bad pattern, because we add implicit 
dependencies where they are completely not needed. Right now any code that 
imports any airflow package implicitly depends on 90% of core of airflow. Maybe 
we should really consider fixing it for 2.0?

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to