Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Misleading warning when downloading empty blob #25780

Closed
Stevenjin8 opened this issue Aug 19, 2022 · 1 comment
Closed

Misleading warning when downloading empty blob #25780

Stevenjin8 opened this issue Aug 19, 2022 · 1 comment
Assignees
Labels
Client This issue points to a problem in the data-plane of the library. Storage Storage Service (Queues, Blobs, Files)

Comments

@Stevenjin8
Copy link
Contributor

  • Azure Storage Blob:
  • 12.13.0:
  • Ubuntu (WSL 2):
  • 3.9.6:

Describe the bug

Downloading an empty blob logs an error including a traceback despite downloading successfully.

To Reproduce
Steps to reproduce the behavior:

  service_client = BlobServiceClient(
      endpoint, key
  )
  container_client = service_client.get_container_client("mycontainer")
  blob_name = "empty"
  container_client.upload_blob(blob_name, data=BytesIO(), overwrite=True)

  blob = container_client.get_blob_client(blob_name)
  blob.download_blob()

Expected behavior

The code should run without any error or warnings.

Screenshots

Here is the output

(.venv) LAPTOP-E0C4GD2A% python secret/storage.py
Ran into a deserialization error. Ignoring since this is failsafe deserialization
Traceback (most recent call last):
  File "/home/stevenjin8/code/azure-sdk-for-python/sdk/storage/azure-storage-blob/azure/storage/blob/_generated/_serialization.py", line 1506, in failsafe_deserialize
    return self(target_obj, data, content_type=content_type)
  File "/home/stevenjin8/code/azure-sdk-for-python/sdk/storage/azure-storage-blob/azure/storage/blob/_generated/_serialization.py", line 1377, in __call__
    data = self._unpack_content(response_data, content_type)
  File "/home/stevenjin8/code/azure-sdk-for-python/sdk/storage/azure-storage-blob/azure/storage/blob/_generated/_serialization.py", line 1535, in _unpack_content
    raise ValueError("This pipeline didn't have the RawDeserializer policy; can't deserialize")
ValueError: This pipeline didn't have the RawDeserializer policy; can't deserialize

If you miss the first line, it seems like an error occurred.

@github-actions github-actions bot added the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Aug 19, 2022
@azure-sdk azure-sdk added Client This issue points to a problem in the data-plane of the library. needs-team-triage Workflow: This issue needs the team to triage. Storage Storage Service (Queues, Blobs, Files) labels Aug 19, 2022
@ghost ghost removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Aug 19, 2022
@xiangyan99 xiangyan99 removed the needs-team-triage Workflow: This issue needs the team to triage. label Aug 22, 2022
@jalauzon-msft
Copy link
Member

Thanks @Stevenjin8! Closing this one and using customer-reported #25954 to track.

@github-actions github-actions bot locked and limited conversation to collaborators Apr 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Client This issue points to a problem in the data-plane of the library. Storage Storage Service (Queues, Blobs, Files)
Projects
None yet
Development

No branches or pull requests

5 participants