diff --git a/azure-mgmt-containerservice/HISTORY.rst b/azure-mgmt-containerservice/HISTORY.rst index 9ef3f0195062..0fc4e3fe3b81 100644 --- a/azure-mgmt-containerservice/HISTORY.rst +++ b/azure-mgmt-containerservice/HISTORY.rst @@ -3,6 +3,14 @@ Release History =============== +4.2.1 (2018-08-08) +++++++++++++++++++ + +**Bugfixes** + +- Fix some invalid regexp +- Fix invalid definition of CredentialResult + 4.2.0 (2018-07-30) ++++++++++++++++++ diff --git a/azure-mgmt-containerservice/README.rst b/azure-mgmt-containerservice/README.rst index 4b0ff63c695d..92bf434c9d09 100644 --- a/azure-mgmt-containerservice/README.rst +++ b/azure-mgmt-containerservice/README.rst @@ -6,7 +6,7 @@ This is the Microsoft Azure Container Service Management Client Library. Azure Resource Manager (ARM) is the next generation of management APIs that replace the old Azure Service Management (ASM). -This package has been tested with Python 2.7, 3.4, 3.5 and 3.6. +This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7. For the older Azure Service Management (ASM) libraries, see `azure-servicemanagement-legacy `__ library. diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile.py index d9e79e2d2eeb..4ae1aa042b59 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile.py @@ -27,7 +27,7 @@ class ContainerServiceLinuxProfile(Model): """ _validation = { - 'admin_username': {'required': True, 'pattern': r'^[a-z][a-z0-9_-]*$'}, + 'admin_username': {'required': True, 'pattern': r'^[A-Za-z][-A-Za-z0-9_]*$'}, 'ssh': {'required': True}, } diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile_py3.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile_py3.py index 824f20d0da8b..9756107e1c7c 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile_py3.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/container_service_linux_profile_py3.py @@ -27,7 +27,7 @@ class ContainerServiceLinuxProfile(Model): """ _validation = { - 'admin_username': {'required': True, 'pattern': r'^[a-z][a-z0-9_-]*$'}, + 'admin_username': {'required': True, 'pattern': r'^[A-Za-z][-A-Za-z0-9_]*$'}, 'ssh': {'required': True}, } diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results.py index 12d8c7ac1fe4..6360ae308c44 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results.py @@ -18,19 +18,19 @@ class CredentialResults(Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar values: - :vartype values: + :ivar kubeconfigs: + :vartype kubeconfigs: list[~azure.mgmt.containerservice.models.CredentialResult] """ _validation = { - 'values': {'readonly': True}, + 'kubeconfigs': {'readonly': True}, } _attribute_map = { - 'values': {'key': 'values', 'type': '[CredentialResult]'}, + 'kubeconfigs': {'key': 'kubeconfigs', 'type': '[CredentialResult]'}, } def __init__(self, **kwargs): super(CredentialResults, self).__init__(**kwargs) - self.values = None + self.kubeconfigs = None diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results_py3.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results_py3.py index fc52b257dc70..ac5e843261f6 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results_py3.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/models/credential_results_py3.py @@ -18,19 +18,19 @@ class CredentialResults(Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar values: - :vartype values: + :ivar kubeconfigs: + :vartype kubeconfigs: list[~azure.mgmt.containerservice.models.CredentialResult] """ _validation = { - 'values': {'readonly': True}, + 'kubeconfigs': {'readonly': True}, } _attribute_map = { - 'values': {'key': 'values', 'type': '[CredentialResult]'}, + 'kubeconfigs': {'key': 'kubeconfigs', 'type': '[CredentialResult]'}, } def __init__(self, **kwargs) -> None: super(CredentialResults, self).__init__(**kwargs) - self.values = None + self.kubeconfigs = None diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/container_services_operations.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/container_services_operations.py index 9901518494b7..887569a8a13a 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/container_services_operations.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/container_services_operations.py @@ -78,7 +78,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -87,9 +87,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -129,6 +128,7 @@ def _create_or_update_initial( # Construct headers header_parameters = {} + header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) @@ -141,9 +141,8 @@ def _create_or_update_initial( body_content = self._serialize.body(parameters, 'ContainerService') # Construct and send request - request = self._client.put(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.put(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 202]: exp = CloudError(response) @@ -261,7 +260,7 @@ def get( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -270,8 +269,8 @@ def get( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -310,7 +309,6 @@ def _delete_initial( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -319,8 +317,8 @@ def _delete_initial( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.delete(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.delete(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [202, 204]: exp = CloudError(response) @@ -424,7 +422,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -433,9 +431,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -498,7 +495,7 @@ def list_orchestrators( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -507,8 +504,8 @@ def list_orchestrators( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/managed_clusters_operations.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/managed_clusters_operations.py index 891d77138aa7..ee38a71b40e3 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/managed_clusters_operations.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/managed_clusters_operations.py @@ -76,7 +76,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -85,9 +85,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -148,7 +147,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -157,9 +156,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -216,7 +214,7 @@ def get_upgrade_profile( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -225,8 +223,8 @@ def get_upgrade_profile( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -286,7 +284,7 @@ def get_access_profile( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -295,8 +293,8 @@ def get_access_profile( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -351,7 +349,7 @@ def list_cluster_admin_credentials( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -360,8 +358,8 @@ def list_cluster_admin_credentials( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -416,7 +414,7 @@ def list_cluster_user_credentials( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -425,8 +423,8 @@ def list_cluster_user_credentials( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.post(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -481,7 +479,7 @@ def get( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -490,8 +488,8 @@ def get( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -528,6 +526,7 @@ def _create_or_update_initial( # Construct headers header_parameters = {} + header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) @@ -540,9 +539,8 @@ def _create_or_update_initial( body_content = self._serialize.body(parameters, 'ManagedCluster') # Construct and send request - request = self._client.put(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.put(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201]: exp = CloudError(response) @@ -636,6 +634,7 @@ def _update_tags_initial( # Construct headers header_parameters = {} + header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) @@ -648,9 +647,8 @@ def _update_tags_initial( body_content = self._serialize.body(parameters, 'TagsObject') # Construct and send request - request = self._client.patch(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) + request = self._client.patch(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) @@ -738,7 +736,6 @@ def _delete_initial( # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -747,8 +744,8 @@ def _delete_initial( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.delete(url, query_parameters) - response = self._client.send(request, header_parameters, stream=False, **operation_config) + request = self._client.delete(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [202, 204]: exp = CloudError(response) diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/operations.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/operations.py index 83337ae0311b..a43ead3a313c 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/operations.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/operations/operations.py @@ -67,7 +67,7 @@ def internal_paging(next_link=None, raw=False): # Construct headers header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' + header_parameters['Accept'] = 'application/json' if self.config.generate_client_request_id: header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) if custom_headers: @@ -76,9 +76,8 @@ def internal_paging(next_link=None, raw=False): header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, stream=False, **operation_config) + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200]: exp = CloudError(response) diff --git a/azure-mgmt-containerservice/azure/mgmt/containerservice/version.py b/azure-mgmt-containerservice/azure/mgmt/containerservice/version.py index 001170437cef..6460f958f792 100644 --- a/azure-mgmt-containerservice/azure/mgmt/containerservice/version.py +++ b/azure-mgmt-containerservice/azure/mgmt/containerservice/version.py @@ -9,5 +9,5 @@ # regenerated. # -------------------------------------------------------------------------- -VERSION = "4.2.0" +VERSION = "4.2.1" diff --git a/azure-mgmt-containerservice/setup.py b/azure-mgmt-containerservice/setup.py index 185d6e666a0e..eb48b95424f6 100644 --- a/azure-mgmt-containerservice/setup.py +++ b/azure-mgmt-containerservice/setup.py @@ -72,12 +72,14 @@ 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', 'License :: OSI Approved :: MIT License', ], zip_safe=False, packages=find_packages(exclude=["tests"]), install_requires=[ - 'msrestazure>=0.4.27,<2.0.0', + 'msrest>=0.5.0', + 'msrestazure>=0.4.32,<2.0.0', 'azure-common~=1.1', ], cmdclass=cmdclass