Skip to content

Commit 9409563

Browse files
sfc-gh-turbaszeksfc-gh-fpawlowski
authored andcommitted
NO-SNOW: Fix Azure GET returning UPLOADED instead of DOWNLOADED status (#2782)
Co-authored-by: Filip Pawłowski <filip.pawlowski@snowflake.com>
1 parent 1ba4f20 commit 9409563

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

DESCRIPTION.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ Source code is also available at: https://github.com/snowflakedb/snowflake-conne
1010
- v3.18.1(July 15,2026)
1111
- Improved verification of TLS connections (SNOW-3675579).
1212
- Fixed FIPS environments md5 hash issues with multipart upload on Azure.
13+
- Fixed a bug where Azure GET commands would incorrectly set the file status to UPLOADED instead of preserving the DOWNLOADED status during metadata retrieval.
1314

1415
- v3.18.0(October 03,2025)
1516
- Added support for pandas conversion for Day-time and Year-Month Interval types

src/snowflake/connector/azure_storage_client.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,9 @@ def get_file_header(self, filename: str) -> FileHeader | None:
124124
self.retry_count[retry_id] = 0
125125
r = self._send_request_with_authentication_and_retry("HEAD", url, retry_id)
126126
if r.status_code == 200:
127-
meta.result_status = ResultStatus.UPLOADED
127+
# If we are in download path, do not update to UPLOADED
128+
if meta.result_status != ResultStatus.DOWNLOADED:
129+
meta.result_status = ResultStatus.UPLOADED
128130
enc_data_str = r.headers.get(ENCRYPTION_DATA)
129131
encryption_data = None if enc_data_str is None else json.loads(enc_data_str)
130132
encryption_metadata = (

0 commit comments

Comments
 (0)