From 7e776db254953076e932ed2183e1ed49a5ca20a6 Mon Sep 17 00:00:00 2001 From: Malthe Borch Date: Fri, 9 Dec 2022 13:29:39 +0000 Subject: [PATCH] Make arguments 'offset' and 'length' not required (#28234) * Make arguments 'offset' and 'length' not required * Disable implicit optional for azure-storage (mypy) --- airflow/providers/microsoft/azure/hooks/wasb.py | 2 +- setup.cfg | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/airflow/providers/microsoft/azure/hooks/wasb.py b/airflow/providers/microsoft/azure/hooks/wasb.py index 3a7f481a90dcb..27680a5b69408 100644 --- a/airflow/providers/microsoft/azure/hooks/wasb.py +++ b/airflow/providers/microsoft/azure/hooks/wasb.py @@ -385,7 +385,7 @@ def upload( return blob_client.upload_blob(data, blob_type, length=length, **kwargs) def download( - self, container_name, blob_name, offset: int, length: int, **kwargs + self, container_name, blob_name, offset: int | None = None, length: int | None = None, **kwargs ) -> StorageStreamDownloader: """ Downloads a blob to the StorageStreamDownloader diff --git a/setup.cfg b/setup.cfg index 59e6686ab55a8..2274d98e3a90a 100644 --- a/setup.cfg +++ b/setup.cfg @@ -191,5 +191,5 @@ no_implicit_optional = False #Let's assume all azure packages have no implicit optional [mypy-azure.batch.*] no_implicit_optional = False -[mypy-azure.batch.models.*] +[mypy-azure.storage.*] no_implicit_optional = False