Azure / azure-sdk-for-python

This repository is for active development of the Azure SDK for Python. For consumers of the SDK we recommend visiting our public developer docs at https://learn.microsoft.com/python/azure/ or our versioned developer docs at https://azure.github.io/azure-sdk-for-python.
MIT License
4.56k stars 2.79k forks source link

AttributeError: 'StorageManagementClientConfiguration' object has no attribute 'api_version' #35821

Closed yfairweather closed 2 months ago

yfairweather commented 4 months ago

Describe the bug When running StorageManagementClient.storage_accounts.list(), sometimes we run into this error but other times it just works

To Reproduce Steps to reproduce the behavior:

  1. Run StorageManagementClient.storage_accounts.list() and if you get lucky you will hit this backtrace:
    
    Traceback (most recent call last):
    File "/opt/qumulo/env/202404241446/lib/python3.8/site-packages/azure/core/paging.py", line 124, in __next__
    return next(self._page_iterator)
    File "/opt/qumulo/env/202404241446/lib/python3.8/site-packages/azure/core/paging.py", line 76, in __next__
    self._response = self._get_next(self.continuation_token)
    File "/opt/qumulo/env/202404241446/lib/python3.8/site-packages/azure/mgmt/storage/v2023_01_01/operations/_storage_accounts_operations.py", line 1434, in get_next
    request = prepare_request(next_link)
    File "/opt/qumulo/env/202404241446/lib/python3.8/site-packages/azure/mgmt/storage/v2023_01_01/operations/_storage_accounts_operations.py", line 1417, in prepare_request
    _next_request_params["api-version"] = self._config.api_version
    AttributeError: 'StorageManagementClientConfiguration' object has no attribute 'api_version'


**Expected behavior**
The API call should work 100% of the time

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Additional context**
Add any other context about the problem here.
github-actions[bot] commented 4 months ago

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @jalauzon-msft @vincenttran-msft.

msyyc commented 3 months ago

We will make an investigation ASAP.

msyyc commented 3 months ago

Hi @yfairweather Could you show the complete code screenshot? I can't reproduce the error locally.

github-actions[bot] commented 3 months ago

Hi @yfairweather. Thank you for opening this issue and giving us the opportunity to assist. To help our team better understand your issue and the details of your scenario please provide a response to the question asked above or the information requested above. This will help us more accurately address your issue.

github-actions[bot] commented 3 months ago

Hi @yfairweather, we're sending this friendly reminder because we haven't heard back from you in 7 days. We need more information about this issue to help address it. Please be sure to give us your input. If we don't hear back from you within 14 days of this comment the issue will be automatically closed. Thank you!