To install:
$ pip install msrestazure
Features
- Add cloud definitions for public Azure, German Azure, China Azure and Azure Gov
- Add get_cloud_from_metadata_endpoint to automatically create a Cloud object from an ARM endpoint
- Add cloud_environment to all Credentials objects (except AdalAuthentication)
Note
- This deprecates "china=True", to be replaced by "cloud_environment=AZURE_CHINA_CLOUD"
Example:
from msrestazure.azure_cloud import AZURE_CHINA_CLOUD
from msrestazure.azure_active_directory import UserPassCredentials
credentials = UserPassCredentials(
login,
password,
cloud_environment=AZURE_CHINA_CLOUD
)
base_url of SDK client can be pointed to "cloud_environment.endpoints.resource_manager" for basic scenario:
Example:
from msrestazure.azure_cloud import AZURE_CHINA_CLOUD
from msrestazure.azure_active_directory import UserPassCredentials
from azure.mgmt.resource import ResourceManagementClient
credentials = UserPassCredentials(
login,
password,
cloud_environment=AZURE_CHINA_CLOUD
)
client = ResourceManagementClient(
credentials,
subscription_id,
base_url=AZURE_CHINA_CLOUD.endpoints.resource_manager
)
Azure Stack connection can be done:
from msrestazure.azure_cloud import get_cloud_from_metadata_endpoint
from msrestazure.azure_active_directory import UserPassCredentials
from azure.mgmt.resource import ResourceManagementClient
mystack_cloud = get_cloud_from_metadata_endpoint("https://myazurestack-arm-endpoint.com")
credentials = UserPassCredentials(
login,
password,
cloud_environment=mystack_cloud
)
client = ResourceManagementClient(
credentials,
subscription_id,
base_url=mystack_cloud.endpoints.resource_manager
)
Bugfixes
- Accept PATCH/201 as LRO valid state
- Close token session on exit (ServicePrincipal and UserPassword credentials)
Features
- Add proxies parameters to ServicePrincipal and UserPassword credentials class #29
- Add automatic Azure provider registration if needed (requires msrest 0.4.10) #28
Thank you to likel for his contribution
Bugfixes
- Fix LRO if first call never returns 200, but ends on 201 (#26)
- FiX LRO AttributeError if timeout is short (#21)
Features
- Expose a "status()" method in AzureOperationPoller (#18)
Bugfixes
- Adding accept_language and `generate_client_request_id ` default values
Bugfixes
Refactor Long Running Operation algorithm.
- There is no breaking changes, however you might need to record again your offline HTTP records if you use unittests with VCRpy.
- Fix a couple of latent bugs
New features
- Add AdalAuthentification class to wrap ADAL library (Azure#8)
Bugfixes
- More informative and well-formed CloudError exceptions (Azure/autorest#1460)
- Raise CustomException is defined in Swagger (Azure/autorest#1404)
Bugfixes
- Make AzureOperationPoller thread as daemon (do not block anymore a Ctrl+C) (Azure/autorest#1379)
Bugfixes
- Better exception message (Azure/autorest#1300)
This version needs msrest >= 0.4.3
Bugfixes
- Fix for LRO PUT operation Azure/autorest#1133
Update msrest dependency to 0.4.0
Bugfixes
- Fix for several AAD issues Azure/autorest#1055
- Fix for LRO PATCH bug and refactor Azure/autorest#993
Behaviour changes
- Needs Autorest > 0.17.0 Nightly 20160525
Update msrest dependency to 0.3.0
Bugfixes
- Read only values are no longer in __init__ or sent to the server (Azure/autorest#959)
- Useless kwarg removed
Behaviour changes
- Needs Autorest > 0.16.0 Nightly 20160426
Bugfixes
- Fix AzurePollerOperation if Swagger defines provisioning status as enum type (Azure/autorest#892)
Update msrest dependency to 0.2.0
Behaviour change
- async methods called with raw=True don't return anymore AzureOperationPoller but ClientRawResponse
- Needs Autorest > 0.16.0 Nightly 20160324
Update msrest dependency to 0.1.3
Bugfixes
- AzureOperationPoller.wait() failed to raise exception if query error (Azure/autorest#856)
Bugfixes
- Source package corrupted in Pypi (Azure/autorest#799)
Behaviour change
- Replaced _required attribute in CloudErrorData class with _validation dict.
Bugfixes
- Fixed AAD bug to include connection verification in UserPassCredentials. (Azure/autorest#725)
- Source package corrupted in Pypi (Azure/autorest#718)
- Initial release.