You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/02/18 13:18:41 UTC

[GitHub] [airflow] potiuk edited a comment on issue #13185: Cannot import name 'BlobServiceClient'

potiuk edited a comment on issue #13185:
URL: https://github.com/apache/airflow/issues/13185#issuecomment-781337172


   > This is still an issue for me with latest 1.10.x and latest backport providers release.
   
   Hey @feluelle You likely have the old `azure-storage` library installed. The problem was that there were two libraries:
   * legacy (very old) "azure-storage' (https://pypi.org/project/azure-storage/) 
   * new - set of "azure-storage-*" libraries that replace the storage one. For example (https://pypi.org/project/azure-storage-blob/ or https://pypi.org/project/azure-storage-logging/). 
   
   The problem was that azure did a very, very bad thing. Both libraries have overlapping packages and they can override each other when both legacy and new libraries are installed. If you have 'azure-storage' and 'azure-storage-blob', the set of classes available in `azure.storage.blob` depend on which is the SEQUENCE of installing the two libraries and whethere they were installed with --force or not. Total mess.
   
   So if you want to bring the situation under control - remove 'azure-storage' and reinstall 'azure-storage-*' packages you have. That should help with the error.  If you install 2.0.1+ from scratch, the problem is gone (we have no more `azure-storage` dependency. However in 1.10 you need to install airflow without `[azure]` extra and then add 'apache-airflow-providers-backports-azure'.  Or remove storage and reinstall the 'azure-storage-*'.
   
   Let me know if either of those worked.
   
   I hope it helps. Maybe also someone could describe it nicely somewhere else in the docs ;) ? 


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