mjpieters commented on a change in pull request #12694:
URL: https://github.com/apache/airflow/pull/12694#discussion_r532197104



##########
File path: setup.cfg
##########
@@ -100,6 +100,7 @@ install_requires =
     funcsigs>=1.0.0, <2.0.0
     graphviz>=0.12
     gunicorn>=19.5.0, <20.0
+    importlib_metadata~=1.7 # We could work with 3.1, but argparse needs <2

Review comment:
       Did you meant `argcomplete` perhaps? I note that `argcomplete` has been 
[updated to support `importlib_metadata` 
3.x](https://github.com/kislyuk/argcomplete/blob/develop/Changes.rst) (and 
otherwise only has bugfixes, looks like a desireable upgrade).
   
   And if 3.1 works, please widen the pin to `>=1.7,<4`; the 
`argcomplete~=1.10` pin above *already lets you use `importlib_metadata` 3.1* 
if you have the newer `argcomplete` installed.
   
   Also, Python 3.8 doesn't need `importlib_metadata` anymore, and 
`argcomplete` correctly won't depend on it in 3.8 and up. Please do so here too:
   
   ```
        importlib_metadata>=1.7,<4;python_version<="3.7"
   ```
   
   and make the imports conditional:
   
   ```python
   try:
       # 3.8 and up
       from importlib import metadata as importlib_metadata
   except ImportError:
       # use the backport
       import importlib_metadata
   ```
   
   If you update the `argcomplete` dependency too, then you'd not even have to 
set the `>=1.7` lower bound, `~=3.1` would do.




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