ephraimbuddy commented on a change in pull request #18287:
URL: https://github.com/apache/airflow/pull/18287#discussion_r709937544



##########
File path: airflow/providers/microsoft/azure/hooks/wasb.py
##########
@@ -172,7 +172,7 @@ def _get_blob_client(self, container_name: str, blob_name: 
str) -> BlobClient:
         :param blob_name: The name of the blob. This needs not be existing
         :type blob_name: str
         """
-        container_client = self.create_container(container_name)
+        container_client = self._get_container_client(container_name)

Review comment:
       We can actually make this a breaking change but have an argument on the 
method instead of try/except. Not Ok to do a write operation when you only have 
a` read-only` perms. So I will go for:
   ```python
   def _get_blob_client(self, container_name: str, blob_name: str, 
existing_container=True):
       if existing_container:
           container_client = self._get_container_client(container_name)
      else:
           container_client = self.create_container(container_name)
   ...
   ```
   We have many methods that depend on this, so changing it would mean a 
breaking change but @potiuk can advise the best option here
   
   
   




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

To unsubscribe, e-mail: [email protected]

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


Reply via email to