From ebf2f8de065c1db60b2bc71c2be2ca43c3d05efd Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Tue, 19 Nov 2024 00:53:26 +0000 Subject: [PATCH] CodeGen from PR 30530 in Azure/azure-rest-api-specs Merge 4d4e2d9fb11c22c998b0fc53311c23e723e96c13 into 436b98d8f2146f4cb1ba1d8271039ea95a43022c --- .../_meta.json | 6 +- .../mgmt/desktopvirtualization/__init__.py | 12 +- .../desktopvirtualization/_configuration.py | 5 +- .../_desktop_virtualization_mgmt_client.py | 5 +- .../desktopvirtualization/_serialization.py | 424 +++++++++++------- .../mgmt/desktopvirtualization/_version.py | 2 +- .../desktopvirtualization/aio/__init__.py | 12 +- .../aio/_configuration.py | 5 +- .../_desktop_virtualization_mgmt_client.py | 5 +- .../aio/operations/__init__.py | 46 +- .../_app_attach_package_info_operations.py | 7 +- .../_app_attach_package_operations.py | 21 +- .../_application_groups_operations.py | 21 +- .../operations/_applications_operations.py | 17 +- .../aio/operations/_desktops_operations.py | 11 +- .../aio/operations/_host_pools_operations.py | 23 +- .../aio/operations/_msix_images_operations.py | 7 +- .../operations/_msix_packages_operations.py | 17 +- .../aio/operations/_operations.py | 7 +- ...private_endpoint_connections_operations.py | 27 +- .../_private_link_resources_operations.py | 9 +- ...ling_plan_personal_schedules_operations.py | 17 +- ...caling_plan_pooled_schedules_operations.py | 17 +- .../operations/_scaling_plans_operations.py | 23 +- .../operations/_session_hosts_operations.py | 15 +- .../_start_menu_items_operations.py | 7 +- .../operations/_user_sessions_operations.py | 27 +- .../aio/operations/_workspaces_operations.py | 21 +- .../desktopvirtualization/models/__init__.py | 267 ++++++----- ...esktop_virtualization_mgmt_client_enums.py | 48 ++ .../models/_models_py3.py | 161 ++++++- .../operations/__init__.py | 46 +- .../_app_attach_package_info_operations.py | 9 +- .../_app_attach_package_operations.py | 29 +- .../_application_groups_operations.py | 29 +- .../operations/_applications_operations.py | 25 +- .../operations/_desktops_operations.py | 17 +- .../operations/_host_pools_operations.py | 38 +- .../operations/_msix_images_operations.py | 9 +- .../operations/_msix_packages_operations.py | 25 +- .../operations/_operations.py | 9 +- ...private_endpoint_connections_operations.py | 38 +- .../_private_link_resources_operations.py | 13 +- ...ling_plan_personal_schedules_operations.py | 25 +- ...caling_plan_pooled_schedules_operations.py | 25 +- .../operations/_scaling_plans_operations.py | 33 +- .../operations/_session_hosts_operations.py | 21 +- .../_start_menu_items_operations.py | 9 +- .../operations/_user_sessions_operations.py | 33 +- .../operations/_workspaces_operations.py | 29 +- .../app_attach_package_create.py | 2 +- .../app_attach_package_delete.py | 2 +- .../app_attach_package_get.py | 2 +- .../app_attach_package_info_import_post.py | 2 +- ...p_attach_package_list_by_resource_group.py | 2 +- ...app_attach_package_list_by_subscription.py | 2 +- .../app_attach_package_update.py | 2 +- .../generated_samples/application_create.py | 2 +- .../generated_samples/application_delete.py | 2 +- .../generated_samples/application_get.py | 2 +- .../application_group_create.py | 2 +- .../application_group_delete.py | 2 +- .../application_group_get.py | 2 +- ...pplication_group_list_by_resource_group.py | 2 +- .../application_group_list_by_subscription.py | 2 +- .../application_group_update.py | 2 +- .../generated_samples/application_list.py | 2 +- .../generated_samples/application_update.py | 2 +- .../generated_samples/desktop_get.py | 2 +- .../generated_samples/desktop_list.py | 2 +- .../generated_samples/desktop_update.py | 2 +- .../generated_samples/host_pool_create.py | 6 +- .../generated_samples/host_pool_delete.py | 2 +- .../generated_samples/host_pool_get.py | 2 +- .../generated_samples/host_pool_list.py | 2 +- .../host_pool_list_by_resource_group.py | 2 +- .../generated_samples/host_pool_update.py | 2 +- ...host_pools_list_registration_token_post.py | 2 +- ..._pools_retrieve_registration_token_post.py | 2 +- .../generated_samples/msix_package_create.py | 2 +- .../generated_samples/msix_package_delete.py | 2 +- .../generated_samples/msix_package_get.py | 2 +- .../generated_samples/msix_package_list.py | 2 +- .../generated_samples/msix_package_update.py | 2 +- .../operation_description_list.py | 2 +- ...endpoint_connection_delete_by_host_pool.py | 2 +- ...endpoint_connection_delete_by_workspace.py | 2 +- ...te_endpoint_connection_get_by_host_pool.py | 2 +- ...te_endpoint_connection_get_by_workspace.py | 2 +- ...e_endpoint_connection_list_by_host_pool.py | 2 +- ...e_endpoint_connection_list_by_workspace.py | 2 +- ...endpoint_connection_update_by_host_pool.py | 2 +- ...endpoint_connection_update_by_workspace.py | 2 +- ...rivate_link_resources_list_by_host_pool.py | 2 +- ...rivate_link_resources_list_by_workspace.py | 2 +- .../generated_samples/scaling_plan_create.py | 2 +- .../generated_samples/scaling_plan_delete.py | 2 +- .../generated_samples/scaling_plan_get.py | 2 +- .../scaling_plan_list_by_host_pool.py | 2 +- .../scaling_plan_list_by_resource_group.py | 2 +- .../scaling_plan_list_by_subscription.py | 2 +- .../scaling_plan_personal_schedule_create.py | 2 +- .../scaling_plan_personal_schedule_delete.py | 2 +- .../scaling_plan_personal_schedule_get.py | 2 +- .../scaling_plan_personal_schedule_list.py | 2 +- .../scaling_plan_personal_schedule_update.py | 2 +- .../scaling_plan_pooled_schedule_create.py | 2 +- .../scaling_plan_pooled_schedule_delete.py | 2 +- .../scaling_plan_pooled_schedule_get.py | 2 +- .../scaling_plan_pooled_schedule_list.py | 2 +- .../scaling_plan_pooled_schedule_update.py | 2 +- .../generated_samples/scaling_plan_update.py | 2 +- .../generated_samples/session_host_delete.py | 2 +- .../generated_samples/session_host_get.py | 2 +- .../generated_samples/session_host_list.py | 2 +- .../generated_samples/session_host_update.py | 2 +- .../generated_samples/start_menu_item_list.py | 2 +- .../generated_samples/user_session_delete.py | 2 +- .../user_session_disconnect_post.py | 2 +- .../generated_samples/user_session_get.py | 2 +- .../generated_samples/user_session_list.py | 2 +- .../user_session_list_by_host_pool.py | 2 +- .../user_session_send_message_post.py | 2 +- .../generated_samples/workspace_create.py | 2 +- .../generated_samples/workspace_delete.py | 2 +- .../generated_samples/workspace_get.py | 2 +- .../workspace_list_by_resource_group.py | 2 +- .../workspace_list_by_subscription.py | 2 +- .../generated_samples/workspace_update.py | 2 +- .../generated_tests/conftest.py | 2 +- ...mgmt_app_attach_package_info_operations.py | 4 +- ...pp_attach_package_info_operations_async.py | 4 +- ...tion_mgmt_app_attach_package_operations.py | 24 +- ...gmt_app_attach_package_operations_async.py | 24 +- ...tion_mgmt_application_groups_operations.py | 24 +- ...gmt_application_groups_operations_async.py | 24 +- ...ualization_mgmt_applications_operations.py | 20 +- ...tion_mgmt_applications_operations_async.py | 20 +- ...virtualization_mgmt_desktops_operations.py | 12 +- ...lization_mgmt_desktops_operations_async.py | 12 +- ...rtualization_mgmt_host_pools_operations.py | 36 +- ...zation_mgmt_host_pools_operations_async.py | 36 +- ...tualization_mgmt_msix_images_operations.py | 4 +- ...ation_mgmt_msix_images_operations_async.py | 4 +- ...alization_mgmt_msix_packages_operations.py | 20 +- ...ion_mgmt_msix_packages_operations_async.py | 20 +- ..._desktop_virtualization_mgmt_operations.py | 4 +- ...op_virtualization_mgmt_operations_async.py | 4 +- ...private_endpoint_connections_operations.py | 32 +- ...e_endpoint_connections_operations_async.py | 32 +- ..._mgmt_private_link_resources_operations.py | 8 +- ...private_link_resources_operations_async.py | 8 +- ...ling_plan_personal_schedules_operations.py | 20 +- ...lan_personal_schedules_operations_async.py | 20 +- ...caling_plan_pooled_schedules_operations.py | 20 +- ..._plan_pooled_schedules_operations_async.py | 20 +- ...alization_mgmt_scaling_plans_operations.py | 28 +- ...ion_mgmt_scaling_plans_operations_async.py | 28 +- ...alization_mgmt_session_hosts_operations.py | 16 +- ...ion_mgmt_session_hosts_operations_async.py | 16 +- ...zation_mgmt_start_menu_items_operations.py | 4 +- ..._mgmt_start_menu_items_operations_async.py | 4 +- ...alization_mgmt_user_sessions_operations.py | 24 +- ...ion_mgmt_user_sessions_operations_async.py | 24 +- ...rtualization_mgmt_workspaces_operations.py | 24 +- ...zation_mgmt_workspaces_operations_async.py | 24 +- 166 files changed, 1430 insertions(+), 1136 deletions(-) diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/_meta.json b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/_meta.json index e7cc76c50156..29a4d42cade5 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/_meta.json +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/_meta.json @@ -1,11 +1,11 @@ { - "commit": "f1e65f90e77a72258801439e757fc76ecb13a7fc", + "commit": "d4b69f0746c5a6fc9adbc7bc0f11eb84a21d82d3", "repository_url": "https://github.com/Azure/azure-rest-api-specs", "autorest": "3.10.2", "use": [ - "@autorest/python@6.19.0", + "@autorest/python@6.26.4", "@autorest/modelerfour@4.27.0" ], - "autorest_command": "autorest specification/desktopvirtualization/resource-manager/readme.md --generate-sample=True --generate-test=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --tag=package-2024-04 --use=@autorest/python@6.19.0 --use=@autorest/modelerfour@4.27.0 --version=3.10.2 --version-tolerant=False", + "autorest_command": "autorest specification/desktopvirtualization/resource-manager/readme.md --generate-sample=True --generate-test=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-python/sdk --use=@autorest/python@6.26.4 --use=@autorest/modelerfour@4.27.0 --version=3.10.2 --version-tolerant=False", "readme": "specification/desktopvirtualization/resource-manager/readme.md" } \ No newline at end of file diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/__init__.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/__init__.py index 8a587f87b999..23116ec32b46 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/__init__.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/__init__.py @@ -5,15 +5,21 @@ # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- +# pylint: disable=wrong-import-position -from ._desktop_virtualization_mgmt_client import DesktopVirtualizationMgmtClient +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from ._patch import * # pylint: disable=unused-wildcard-import + +from ._desktop_virtualization_mgmt_client import DesktopVirtualizationMgmtClient # type: ignore from ._version import VERSION __version__ = VERSION try: from ._patch import __all__ as _patch_all - from ._patch import * # pylint: disable=unused-wildcard-import + from ._patch import * except ImportError: _patch_all = [] from ._patch import patch_sdk as _patch_sdk @@ -21,6 +27,6 @@ __all__ = [ "DesktopVirtualizationMgmtClient", ] -__all__.extend([p for p in _patch_all if p not in __all__]) +__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore _patch_sdk() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_configuration.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_configuration.py index 835e232059af..c1fbb514a58f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_configuration.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_configuration.py @@ -14,7 +14,6 @@ from ._version import VERSION if TYPE_CHECKING: - # pylint: disable=unused-import,ungrouped-imports from azure.core.credentials import TokenCredential @@ -28,13 +27,13 @@ class DesktopVirtualizationMgmtClientConfiguration: # pylint: disable=too-many- :type credential: ~azure.core.credentials.TokenCredential :param subscription_id: The ID of the target subscription. The value must be an UUID. Required. :type subscription_id: str - :keyword api_version: Api Version. Default value is "2024-04-03". Note that overriding this + :keyword api_version: Api Version. Default value is "2024-09-10". Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str """ def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None: - api_version: str = kwargs.pop("api_version", "2024-04-03") + api_version: str = kwargs.pop("api_version", "2024-09-10") if credential is None: raise ValueError("Parameter 'credential' must not be None.") diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_desktop_virtualization_mgmt_client.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_desktop_virtualization_mgmt_client.py index 0205fa978041..cadbd0aac095 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_desktop_virtualization_mgmt_client.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_desktop_virtualization_mgmt_client.py @@ -40,11 +40,10 @@ ) if TYPE_CHECKING: - # pylint: disable=unused-import,ungrouped-imports from azure.core.credentials import TokenCredential -class DesktopVirtualizationMgmtClient: # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes +class DesktopVirtualizationMgmtClient: # pylint: disable=too-many-instance-attributes """DesktopVirtualizationMgmtClient. :ivar operations: Operations operations @@ -96,7 +95,7 @@ class DesktopVirtualizationMgmtClient: # pylint: disable=client-accepts-api-ver :type subscription_id: str :param base_url: Service URL. Default value is "https://management.azure.com". :type base_url: str - :keyword api_version: Api Version. Default value is "2024-04-03". Note that overriding this + :keyword api_version: Api Version. Default value is "2024-09-10". Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str """ diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_serialization.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_serialization.py index 8139854b97bb..ce17d1798ce7 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_serialization.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_serialization.py @@ -1,3 +1,4 @@ +# pylint: disable=too-many-lines # -------------------------------------------------------------------------- # # Copyright (c) Microsoft Corporation. All rights reserved. @@ -24,7 +25,6 @@ # # -------------------------------------------------------------------------- -# pylint: skip-file # pyright: reportUnnecessaryTypeIgnoreComment=false from base64 import b64decode, b64encode @@ -52,7 +52,6 @@ MutableMapping, Type, List, - Mapping, ) try: @@ -91,6 +90,8 @@ def deserialize_from_text(cls, data: Optional[Union[AnyStr, IO]], content_type: :param data: Input, could be bytes or stream (will be decoded with UTF8) or text :type data: str or bytes or IO :param str content_type: The content type. + :return: The deserialized data. + :rtype: object """ if hasattr(data, "read"): # Assume a stream @@ -112,7 +113,7 @@ def deserialize_from_text(cls, data: Optional[Union[AnyStr, IO]], content_type: try: return json.loads(data_as_str) except ValueError as err: - raise DeserializationError("JSON is invalid: {}".format(err), err) + raise DeserializationError("JSON is invalid: {}".format(err), err) from err elif "xml" in (content_type or []): try: @@ -155,6 +156,11 @@ def deserialize_from_http_generics(cls, body_bytes: Optional[Union[AnyStr, IO]], Use bytes and headers to NOT use any requests/aiohttp or whatever specific implementation. Headers will tested for "content-type" + + :param bytes body_bytes: The body of the response. + :param dict headers: The headers of the response. + :returns: The deserialized data. + :rtype: object """ # Try to use content-type from headers if available content_type = None @@ -184,15 +190,30 @@ class UTC(datetime.tzinfo): """Time Zone info for handling UTC""" def utcoffset(self, dt): - """UTF offset for UTC is 0.""" + """UTF offset for UTC is 0. + + :param datetime.datetime dt: The datetime + :returns: The offset + :rtype: datetime.timedelta + """ return datetime.timedelta(0) def tzname(self, dt): - """Timestamp representation.""" + """Timestamp representation. + + :param datetime.datetime dt: The datetime + :returns: The timestamp representation + :rtype: str + """ return "Z" def dst(self, dt): - """No daylight saving for UTC.""" + """No daylight saving for UTC. + + :param datetime.datetime dt: The datetime + :returns: The daylight saving time + :rtype: datetime.timedelta + """ return datetime.timedelta(hours=1) @@ -206,7 +227,7 @@ class _FixedOffset(datetime.tzinfo): # type: ignore :param datetime.timedelta offset: offset in timedelta format """ - def __init__(self, offset): + def __init__(self, offset) -> None: self.__offset = offset def utcoffset(self, dt): @@ -235,24 +256,26 @@ def __getinitargs__(self): _FLATTEN = re.compile(r"(? None: self.additional_properties: Optional[Dict[str, Any]] = {} - for k in kwargs: + for k in kwargs: # pylint: disable=consider-using-dict-items if k not in self._attribute_map: _LOGGER.warning("%s is not a known attribute of class %s and will be ignored", k, self.__class__) elif k in self._validation and self._validation[k].get("readonly", False): @@ -300,13 +330,23 @@ def __init__(self, **kwargs: Any) -> None: setattr(self, k, kwargs[k]) def __eq__(self, other: Any) -> bool: - """Compare objects by comparing all attributes.""" + """Compare objects by comparing all attributes. + + :param object other: The object to compare + :returns: True if objects are equal + :rtype: bool + """ if isinstance(other, self.__class__): return self.__dict__ == other.__dict__ return False def __ne__(self, other: Any) -> bool: - """Compare objects by comparing all attributes.""" + """Compare objects by comparing all attributes. + + :param object other: The object to compare + :returns: True if objects are not equal + :rtype: bool + """ return not self.__eq__(other) def __str__(self) -> str: @@ -326,7 +366,11 @@ def is_xml_model(cls) -> bool: @classmethod def _create_xml_node(cls): - """Create XML node.""" + """Create XML node. + + :returns: The XML node + :rtype: xml.etree.ElementTree.Element + """ try: xml_map = cls._xml_map # type: ignore except AttributeError: @@ -346,7 +390,9 @@ def serialize(self, keep_readonly: bool = False, **kwargs: Any) -> JSON: :rtype: dict """ serializer = Serializer(self._infer_class_models()) - return serializer._serialize(self, keep_readonly=keep_readonly, **kwargs) # type: ignore + return serializer._serialize( # type: ignore # pylint: disable=protected-access + self, keep_readonly=keep_readonly, **kwargs + ) def as_dict( self, @@ -380,12 +426,15 @@ def my_key_transformer(key, attr_desc, value): If you want XML serialization, you can pass the kwargs is_xml=True. + :param bool keep_readonly: If you want to serialize the readonly attributes :param function key_transformer: A key transformer function. :returns: A dict JSON compatible object :rtype: dict """ serializer = Serializer(self._infer_class_models()) - return serializer._serialize(self, key_transformer=key_transformer, keep_readonly=keep_readonly, **kwargs) # type: ignore + return serializer._serialize( # type: ignore # pylint: disable=protected-access + self, key_transformer=key_transformer, keep_readonly=keep_readonly, **kwargs + ) @classmethod def _infer_class_models(cls): @@ -395,7 +444,7 @@ def _infer_class_models(cls): client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} if cls.__name__ not in client_models: raise ValueError("Not Autorest generated code") - except Exception: + except Exception: # pylint: disable=broad-exception-caught # Assume it's not Autorest generated (tests?). Add ourselves as dependencies. client_models = {cls.__name__: cls} return client_models @@ -408,6 +457,7 @@ def deserialize(cls: Type[ModelType], data: Any, content_type: Optional[str] = N :param str content_type: JSON by default, set application/xml if XML. :returns: An instance of this model :raises: DeserializationError if something went wrong + :rtype: ModelType """ deserializer = Deserializer(cls._infer_class_models()) return deserializer(cls.__name__, data, content_type=content_type) # type: ignore @@ -426,9 +476,11 @@ def from_dict( and last_rest_key_case_insensitive_extractor) :param dict data: A dict using RestAPI structure + :param function key_extractors: A key extractor function. :param str content_type: JSON by default, set application/xml if XML. :returns: An instance of this model :raises: DeserializationError if something went wrong + :rtype: ModelType """ deserializer = Deserializer(cls._infer_class_models()) deserializer.key_extractors = ( # type: ignore @@ -448,21 +500,25 @@ def _flatten_subtype(cls, key, objects): return {} result = dict(cls._subtype_map[key]) for valuetype in cls._subtype_map[key].values(): - result.update(objects[valuetype]._flatten_subtype(key, objects)) + result.update(objects[valuetype]._flatten_subtype(key, objects)) # pylint: disable=protected-access return result @classmethod def _classify(cls, response, objects): """Check the class _subtype_map for any child classes. We want to ignore any inherited _subtype_maps. - Remove the polymorphic key from the initial data. + + :param dict response: The initial data + :param dict objects: The class objects + :returns: The class to be used + :rtype: class """ for subtype_key in cls.__dict__.get("_subtype_map", {}).keys(): subtype_value = None if not isinstance(response, ET.Element): rest_api_response_key = cls._get_rest_key_parts(subtype_key)[-1] - subtype_value = response.pop(rest_api_response_key, None) or response.pop(subtype_key, None) + subtype_value = response.get(rest_api_response_key, None) or response.get(subtype_key, None) else: subtype_value = xml_key_extractor(subtype_key, cls._attribute_map[subtype_key], response) if subtype_value: @@ -501,11 +557,13 @@ def _decode_attribute_map_key(key): inside the received data. :param str key: A key string from the generated code + :returns: The decoded key + :rtype: str """ return key.replace("\\.", ".") -class Serializer(object): +class Serializer(object): # pylint: disable=too-many-public-methods """Request object model serializer.""" basic_types = {str: "str", int: "int", bool: "bool", float: "float"} @@ -540,7 +598,7 @@ class Serializer(object): "multiple": lambda x, y: x % y != 0, } - def __init__(self, classes: Optional[Mapping[str, type]] = None): + def __init__(self, classes: Optional[Mapping[str, type]] = None) -> None: self.serialize_type = { "iso-8601": Serializer.serialize_iso, "rfc-1123": Serializer.serialize_rfc, @@ -560,13 +618,16 @@ def __init__(self, classes: Optional[Mapping[str, type]] = None): self.key_transformer = full_restapi_key_transformer self.client_side_validation = True - def _serialize(self, target_obj, data_type=None, **kwargs): + def _serialize( # pylint: disable=too-many-nested-blocks, too-many-branches, too-many-statements, too-many-locals + self, target_obj, data_type=None, **kwargs + ): """Serialize data into a string according to type. - :param target_obj: The data to be serialized. + :param object target_obj: The data to be serialized. :param str data_type: The type to be serialized from. :rtype: str, dict :raises: SerializationError if serialization fails. + :returns: The serialized data. """ key_transformer = kwargs.get("key_transformer", self.key_transformer) keep_readonly = kwargs.get("keep_readonly", False) @@ -592,12 +653,14 @@ def _serialize(self, target_obj, data_type=None, **kwargs): serialized = {} if is_xml_model_serialization: - serialized = target_obj._create_xml_node() + serialized = target_obj._create_xml_node() # pylint: disable=protected-access try: - attributes = target_obj._attribute_map + attributes = target_obj._attribute_map # pylint: disable=protected-access for attr, attr_desc in attributes.items(): attr_name = attr - if not keep_readonly and target_obj._validation.get(attr_name, {}).get("readonly", False): + if not keep_readonly and target_obj._validation.get( # pylint: disable=protected-access + attr_name, {} + ).get("readonly", False): continue if attr_name == "additional_properties" and attr_desc["key"] == "": @@ -633,7 +696,8 @@ def _serialize(self, target_obj, data_type=None, **kwargs): if isinstance(new_attr, list): serialized.extend(new_attr) # type: ignore elif isinstance(new_attr, ET.Element): - # If the down XML has no XML/Name, we MUST replace the tag with the local tag. But keeping the namespaces. + # If the down XML has no XML/Name, + # we MUST replace the tag with the local tag. But keeping the namespaces. if "name" not in getattr(orig_attr, "_xml_map", {}): splitted_tag = new_attr.tag.split("}") if len(splitted_tag) == 2: # Namespace @@ -664,17 +728,17 @@ def _serialize(self, target_obj, data_type=None, **kwargs): except (AttributeError, KeyError, TypeError) as err: msg = "Attribute {} in object {} cannot be serialized.\n{}".format(attr_name, class_name, str(target_obj)) raise SerializationError(msg) from err - else: - return serialized + return serialized def body(self, data, data_type, **kwargs): """Serialize data intended for a request body. - :param data: The data to be serialized. + :param object data: The data to be serialized. :param str data_type: The type to be serialized from. :rtype: dict :raises: SerializationError if serialization fails. :raises: ValueError if data is None + :returns: The serialized request body """ # Just in case this is a dict @@ -703,7 +767,7 @@ def body(self, data, data_type, **kwargs): attribute_key_case_insensitive_extractor, last_rest_key_case_insensitive_extractor, ] - data = deserializer._deserialize(data_type, data) + data = deserializer._deserialize(data_type, data) # pylint: disable=protected-access except DeserializationError as err: raise SerializationError("Unable to build a model: " + str(err)) from err @@ -712,9 +776,11 @@ def body(self, data, data_type, **kwargs): def url(self, name, data, data_type, **kwargs): """Serialize data intended for a URL path. - :param data: The data to be serialized. + :param str name: The name of the URL path parameter. + :param object data: The data to be serialized. :param str data_type: The type to be serialized from. :rtype: str + :returns: The serialized URL path :raises: TypeError if serialization fails. :raises: ValueError if data is None """ @@ -728,21 +794,20 @@ def url(self, name, data, data_type, **kwargs): output = output.replace("{", quote("{")).replace("}", quote("}")) else: output = quote(str(output), safe="") - except SerializationError: - raise TypeError("{} must be type {}.".format(name, data_type)) - else: - return output + except SerializationError as exc: + raise TypeError("{} must be type {}.".format(name, data_type)) from exc + return output def query(self, name, data, data_type, **kwargs): """Serialize data intended for a URL query. - :param data: The data to be serialized. + :param str name: The name of the query parameter. + :param object data: The data to be serialized. :param str data_type: The type to be serialized from. - :keyword bool skip_quote: Whether to skip quote the serialized result. - Defaults to False. :rtype: str, list :raises: TypeError if serialization fails. :raises: ValueError if data is None + :returns: The serialized query parameter """ try: # Treat the list aside, since we don't want to encode the div separator @@ -759,19 +824,20 @@ def query(self, name, data, data_type, **kwargs): output = str(output) else: output = quote(str(output), safe="") - except SerializationError: - raise TypeError("{} must be type {}.".format(name, data_type)) - else: - return str(output) + except SerializationError as exc: + raise TypeError("{} must be type {}.".format(name, data_type)) from exc + return str(output) def header(self, name, data, data_type, **kwargs): """Serialize data intended for a request header. - :param data: The data to be serialized. + :param str name: The name of the header. + :param object data: The data to be serialized. :param str data_type: The type to be serialized from. :rtype: str :raises: TypeError if serialization fails. :raises: ValueError if data is None + :returns: The serialized header """ try: if data_type in ["[str]"]: @@ -780,21 +846,20 @@ def header(self, name, data, data_type, **kwargs): output = self.serialize_data(data, data_type, **kwargs) if data_type == "bool": output = json.dumps(output) - except SerializationError: - raise TypeError("{} must be type {}.".format(name, data_type)) - else: - return str(output) + except SerializationError as exc: + raise TypeError("{} must be type {}.".format(name, data_type)) from exc + return str(output) def serialize_data(self, data, data_type, **kwargs): """Serialize generic data according to supplied data type. - :param data: The data to be serialized. + :param object data: The data to be serialized. :param str data_type: The type to be serialized from. - :param bool required: Whether it's essential that the data not be - empty or None :raises: AttributeError if required data is None. :raises: ValueError if data is None :raises: SerializationError if serialization fails. + :returns: The serialized data. + :rtype: str, int, float, bool, dict, list """ if data is None: raise ValueError("No value for given attribute") @@ -805,7 +870,7 @@ def serialize_data(self, data, data_type, **kwargs): if data_type in self.basic_types.values(): return self.serialize_basic(data, data_type, **kwargs) - elif data_type in self.serialize_type: + if data_type in self.serialize_type: return self.serialize_type[data_type](data, **kwargs) # If dependencies is empty, try with current data class @@ -821,11 +886,10 @@ def serialize_data(self, data, data_type, **kwargs): except (ValueError, TypeError) as err: msg = "Unable to serialize value: {!r} as type: {!r}." raise SerializationError(msg.format(data, data_type)) from err - else: - return self._serialize(data, **kwargs) + return self._serialize(data, **kwargs) @classmethod - def _get_custom_serializers(cls, data_type, **kwargs): + def _get_custom_serializers(cls, data_type, **kwargs): # pylint: disable=inconsistent-return-statements custom_serializer = kwargs.get("basic_types_serializers", {}).get(data_type) if custom_serializer: return custom_serializer @@ -841,23 +905,26 @@ def serialize_basic(cls, data, data_type, **kwargs): - basic_types_serializers dict[str, callable] : If set, use the callable as serializer - is_xml bool : If set, use xml_basic_types_serializers - :param data: Object to be serialized. + :param obj data: Object to be serialized. :param str data_type: Type of object in the iterable. + :rtype: str, int, float, bool + :return: serialized object """ custom_serializer = cls._get_custom_serializers(data_type, **kwargs) if custom_serializer: return custom_serializer(data) if data_type == "str": return cls.serialize_unicode(data) - return eval(data_type)(data) # nosec + return eval(data_type)(data) # nosec # pylint: disable=eval-used @classmethod def serialize_unicode(cls, data): """Special handling for serializing unicode strings in Py2. Encode to UTF-8 if unicode, otherwise handle as a str. - :param data: Object to be serialized. + :param str data: Object to be serialized. :rtype: str + :return: serialized object """ try: # If I received an enum, return its value return data.value @@ -871,8 +938,7 @@ def serialize_unicode(cls, data): return data except NameError: return str(data) - else: - return str(data) + return str(data) def serialize_iter(self, data, iter_type, div=None, **kwargs): """Serialize iterable. @@ -882,15 +948,13 @@ def serialize_iter(self, data, iter_type, div=None, **kwargs): serialization_ctxt['type'] should be same as data_type. - is_xml bool : If set, serialize as XML - :param list attr: Object to be serialized. + :param list data: Object to be serialized. :param str iter_type: Type of object in the iterable. - :param bool required: Whether the objects in the iterable must - not be None or empty. :param str div: If set, this str will be used to combine the elements in the iterable into a combined string. Default is 'None'. - :keyword bool do_quote: Whether to quote the serialized result of each iterable element. Defaults to False. :rtype: list, str + :return: serialized iterable """ if isinstance(data, str): raise SerializationError("Refuse str type as a valid iter type.") @@ -945,9 +1009,8 @@ def serialize_dict(self, attr, dict_type, **kwargs): :param dict attr: Object to be serialized. :param str dict_type: Type of object in the dictionary. - :param bool required: Whether the objects in the dictionary must - not be None or empty. :rtype: dict + :return: serialized dictionary """ serialization_ctxt = kwargs.get("serialization_ctxt", {}) serialized = {} @@ -971,7 +1034,7 @@ def serialize_dict(self, attr, dict_type, **kwargs): return serialized - def serialize_object(self, attr, **kwargs): + def serialize_object(self, attr, **kwargs): # pylint: disable=too-many-return-statements """Serialize a generic object. This will be handled as a dictionary. If object passed in is not a basic type (str, int, float, dict, list) it will simply be @@ -979,6 +1042,7 @@ def serialize_object(self, attr, **kwargs): :param dict attr: Object to be serialized. :rtype: dict or str + :return: serialized object """ if attr is None: return None @@ -1003,7 +1067,7 @@ def serialize_object(self, attr, **kwargs): return self.serialize_decimal(attr) # If it's a model or I know this dependency, serialize as a Model - elif obj_type in self.dependencies.values() or isinstance(attr, Model): + if obj_type in self.dependencies.values() or isinstance(attr, Model): return self._serialize(attr) if obj_type == dict: @@ -1034,56 +1098,61 @@ def serialize_enum(attr, enum_obj=None): try: enum_obj(result) # type: ignore return result - except ValueError: + except ValueError as exc: for enum_value in enum_obj: # type: ignore if enum_value.value.lower() == str(attr).lower(): return enum_value.value error = "{!r} is not valid value for enum {!r}" - raise SerializationError(error.format(attr, enum_obj)) + raise SerializationError(error.format(attr, enum_obj)) from exc @staticmethod - def serialize_bytearray(attr, **kwargs): + def serialize_bytearray(attr, **kwargs): # pylint: disable=unused-argument """Serialize bytearray into base-64 string. - :param attr: Object to be serialized. + :param str attr: Object to be serialized. :rtype: str + :return: serialized base64 """ return b64encode(attr).decode() @staticmethod - def serialize_base64(attr, **kwargs): + def serialize_base64(attr, **kwargs): # pylint: disable=unused-argument """Serialize str into base-64 string. - :param attr: Object to be serialized. + :param str attr: Object to be serialized. :rtype: str + :return: serialized base64 """ encoded = b64encode(attr).decode("ascii") return encoded.strip("=").replace("+", "-").replace("/", "_") @staticmethod - def serialize_decimal(attr, **kwargs): + def serialize_decimal(attr, **kwargs): # pylint: disable=unused-argument """Serialize Decimal object to float. - :param attr: Object to be serialized. + :param decimal attr: Object to be serialized. :rtype: float + :return: serialized decimal """ return float(attr) @staticmethod - def serialize_long(attr, **kwargs): + def serialize_long(attr, **kwargs): # pylint: disable=unused-argument """Serialize long (Py2) or int (Py3). - :param attr: Object to be serialized. + :param int attr: Object to be serialized. :rtype: int/long + :return: serialized long """ return _long_type(attr) @staticmethod - def serialize_date(attr, **kwargs): + def serialize_date(attr, **kwargs): # pylint: disable=unused-argument """Serialize Date object into ISO-8601 formatted string. :param Date attr: Object to be serialized. :rtype: str + :return: serialized date """ if isinstance(attr, str): attr = isodate.parse_date(attr) @@ -1091,11 +1160,12 @@ def serialize_date(attr, **kwargs): return t @staticmethod - def serialize_time(attr, **kwargs): + def serialize_time(attr, **kwargs): # pylint: disable=unused-argument """Serialize Time object into ISO-8601 formatted string. :param datetime.time attr: Object to be serialized. :rtype: str + :return: serialized time """ if isinstance(attr, str): attr = isodate.parse_time(attr) @@ -1105,30 +1175,32 @@ def serialize_time(attr, **kwargs): return t @staticmethod - def serialize_duration(attr, **kwargs): + def serialize_duration(attr, **kwargs): # pylint: disable=unused-argument """Serialize TimeDelta object into ISO-8601 formatted string. :param TimeDelta attr: Object to be serialized. :rtype: str + :return: serialized duration """ if isinstance(attr, str): attr = isodate.parse_duration(attr) return isodate.duration_isoformat(attr) @staticmethod - def serialize_rfc(attr, **kwargs): + def serialize_rfc(attr, **kwargs): # pylint: disable=unused-argument """Serialize Datetime object into RFC-1123 formatted string. :param Datetime attr: Object to be serialized. :rtype: str :raises: TypeError if format invalid. + :return: serialized rfc """ try: if not attr.tzinfo: _LOGGER.warning("Datetime with no tzinfo will be considered UTC.") utc = attr.utctimetuple() - except AttributeError: - raise TypeError("RFC1123 object must be valid Datetime object.") + except AttributeError as exc: + raise TypeError("RFC1123 object must be valid Datetime object.") from exc return "{}, {:02} {} {:04} {:02}:{:02}:{:02} GMT".format( Serializer.days[utc.tm_wday], @@ -1141,12 +1213,13 @@ def serialize_rfc(attr, **kwargs): ) @staticmethod - def serialize_iso(attr, **kwargs): + def serialize_iso(attr, **kwargs): # pylint: disable=unused-argument """Serialize Datetime object into ISO-8601 formatted string. :param Datetime attr: Object to be serialized. :rtype: str :raises: SerializationError if format invalid. + :return: serialized iso """ if isinstance(attr, str): attr = isodate.parse_datetime(attr) @@ -1172,13 +1245,14 @@ def serialize_iso(attr, **kwargs): raise TypeError(msg) from err @staticmethod - def serialize_unix(attr, **kwargs): + def serialize_unix(attr, **kwargs): # pylint: disable=unused-argument """Serialize Datetime object into IntTime format. This is represented as seconds. :param Datetime attr: Object to be serialized. :rtype: int :raises: SerializationError if format invalid + :return: serialied unix """ if isinstance(attr, int): return attr @@ -1186,11 +1260,11 @@ def serialize_unix(attr, **kwargs): if not attr.tzinfo: _LOGGER.warning("Datetime with no tzinfo will be considered UTC.") return int(calendar.timegm(attr.utctimetuple())) - except AttributeError: - raise TypeError("Unix time object must be valid Datetime object.") + except AttributeError as exc: + raise TypeError("Unix time object must be valid Datetime object.") from exc -def rest_key_extractor(attr, attr_desc, data): +def rest_key_extractor(attr, attr_desc, data): # pylint: disable=unused-argument key = attr_desc["key"] working_data = data @@ -1211,7 +1285,9 @@ def rest_key_extractor(attr, attr_desc, data): return working_data.get(key) -def rest_key_case_insensitive_extractor(attr, attr_desc, data): +def rest_key_case_insensitive_extractor( # pylint: disable=unused-argument, inconsistent-return-statements + attr, attr_desc, data +): key = attr_desc["key"] working_data = data @@ -1232,17 +1308,29 @@ def rest_key_case_insensitive_extractor(attr, attr_desc, data): return attribute_key_case_insensitive_extractor(key, None, working_data) -def last_rest_key_extractor(attr, attr_desc, data): - """Extract the attribute in "data" based on the last part of the JSON path key.""" +def last_rest_key_extractor(attr, attr_desc, data): # pylint: disable=unused-argument + """Extract the attribute in "data" based on the last part of the JSON path key. + + :param str attr: The attribute to extract + :param dict attr_desc: The attribute description + :param dict data: The data to extract from + :rtype: object + :returns: The extracted attribute + """ key = attr_desc["key"] dict_keys = _FLATTEN.split(key) return attribute_key_extractor(dict_keys[-1], None, data) -def last_rest_key_case_insensitive_extractor(attr, attr_desc, data): +def last_rest_key_case_insensitive_extractor(attr, attr_desc, data): # pylint: disable=unused-argument """Extract the attribute in "data" based on the last part of the JSON path key. This is the case insensitive version of "last_rest_key_extractor" + :param str attr: The attribute to extract + :param dict attr_desc: The attribute description + :param dict data: The data to extract from + :rtype: object + :returns: The extracted attribute """ key = attr_desc["key"] dict_keys = _FLATTEN.split(key) @@ -1279,7 +1367,7 @@ def _extract_name_from_internal_type(internal_type): return xml_name -def xml_key_extractor(attr, attr_desc, data): +def xml_key_extractor(attr, attr_desc, data): # pylint: disable=unused-argument,too-many-return-statements if isinstance(data, dict): return None @@ -1331,22 +1419,21 @@ def xml_key_extractor(attr, attr_desc, data): if is_iter_type: if is_wrapped: return None # is_wrapped no node, we want None - else: - return [] # not wrapped, assume empty list + return [] # not wrapped, assume empty list return None # Assume it's not there, maybe an optional node. # If is_iter_type and not wrapped, return all found children if is_iter_type: if not is_wrapped: return children - else: # Iter and wrapped, should have found one node only (the wrap one) - if len(children) != 1: - raise DeserializationError( - "Tried to deserialize an array not wrapped, and found several nodes '{}'. Maybe you should declare this array as wrapped?".format( - xml_name - ) + # Iter and wrapped, should have found one node only (the wrap one) + if len(children) != 1: + raise DeserializationError( + "Tried to deserialize an array not wrapped, and found several nodes '{}'. Maybe you should declare this array as wrapped?".format( # pylint: disable=line-too-long + xml_name ) - return list(children[0]) # Might be empty list and that's ok. + ) + return list(children[0]) # Might be empty list and that's ok. # Here it's not a itertype, we should have found one element only or empty if len(children) > 1: @@ -1363,9 +1450,9 @@ class Deserializer(object): basic_types = {str: "str", int: "int", bool: "bool", float: "float"} - valid_date = re.compile(r"\d{4}[-]\d{2}[-]\d{2}T\d{2}:\d{2}:\d{2}" r"\.?\d*Z?[-+]?[\d{2}]?:?[\d{2}]?") + valid_date = re.compile(r"\d{4}[-]\d{2}[-]\d{2}T\d{2}:\d{2}:\d{2}\.?\d*Z?[-+]?[\d{2}]?:?[\d{2}]?") - def __init__(self, classes: Optional[Mapping[str, type]] = None): + def __init__(self, classes: Optional[Mapping[str, type]] = None) -> None: self.deserialize_type = { "iso-8601": Deserializer.deserialize_iso, "rfc-1123": Deserializer.deserialize_rfc, @@ -1403,11 +1490,12 @@ def __call__(self, target_obj, response_data, content_type=None): :param str content_type: Swagger "produces" if available. :raises: DeserializationError if deserialization fails. :return: Deserialized object. + :rtype: object """ data = self._unpack_content(response_data, content_type) return self._deserialize(target_obj, data) - def _deserialize(self, target_obj, data): + def _deserialize(self, target_obj, data): # pylint: disable=inconsistent-return-statements """Call the deserializer on a model. Data needs to be already deserialized as JSON or XML ElementTree @@ -1416,12 +1504,13 @@ def _deserialize(self, target_obj, data): :param object data: Object to deserialize. :raises: DeserializationError if deserialization fails. :return: Deserialized object. + :rtype: object """ # This is already a model, go recursive just in case if hasattr(data, "_attribute_map"): constants = [name for name, config in getattr(data, "_validation", {}).items() if config.get("constant")] try: - for attr, mapconfig in data._attribute_map.items(): + for attr, mapconfig in data._attribute_map.items(): # pylint: disable=protected-access if attr in constants: continue value = getattr(data, attr) @@ -1440,13 +1529,13 @@ def _deserialize(self, target_obj, data): if isinstance(response, str): return self.deserialize_data(data, response) - elif isinstance(response, type) and issubclass(response, Enum): + if isinstance(response, type) and issubclass(response, Enum): return self.deserialize_enum(data, response) if data is None or data is CoreNull: return data try: - attributes = response._attribute_map # type: ignore + attributes = response._attribute_map # type: ignore # pylint: disable=protected-access d_attrs = {} for attr, attr_desc in attributes.items(): # Check empty string. If it's not empty, someone has a real "additionalProperties"... @@ -1476,9 +1565,8 @@ def _deserialize(self, target_obj, data): except (AttributeError, TypeError, KeyError) as err: msg = "Unable to deserialize to object: " + class_name # type: ignore raise DeserializationError(msg) from err - else: - additional_properties = self._build_additional_properties(attributes, data) - return self._instantiate_model(response, d_attrs, additional_properties) + additional_properties = self._build_additional_properties(attributes, data) + return self._instantiate_model(response, d_attrs, additional_properties) def _build_additional_properties(self, attribute_map, data): if not self.additional_properties_detection: @@ -1505,6 +1593,8 @@ def _classify_target(self, target, data): :param str target: The target object type to deserialize to. :param str/dict data: The response data to deserialize. + :return: The classified target object and its class name. + :rtype: tuple """ if target is None: return None, None @@ -1516,7 +1606,7 @@ def _classify_target(self, target, data): return target, target try: - target = target._classify(data, self.dependencies) # type: ignore + target = target._classify(data, self.dependencies) # type: ignore # pylint: disable=protected-access except AttributeError: pass # Target is not a Model, no classify return target, target.__class__.__name__ # type: ignore @@ -1531,10 +1621,12 @@ def failsafe_deserialize(self, target_obj, data, content_type=None): :param str target_obj: The target object type to deserialize to. :param str/dict data: The response data to deserialize. :param str content_type: Swagger "produces" if available. + :return: Deserialized object. + :rtype: object """ try: return self(target_obj, data, content_type=content_type) - except: + except: # pylint: disable=bare-except _LOGGER.debug( "Ran into a deserialization error. Ignoring since this is failsafe deserialization", exc_info=True ) @@ -1552,10 +1644,12 @@ def _unpack_content(raw_data, content_type=None): If raw_data is something else, bypass all logic and return it directly. - :param raw_data: Data to be processed. - :param content_type: How to parse if raw_data is a string/bytes. + :param obj raw_data: Data to be processed. + :param str content_type: How to parse if raw_data is a string/bytes. :raises JSONDecodeError: If JSON is requested and parsing is impossible. :raises UnicodeDecodeError: If bytes is not UTF8 + :rtype: object + :return: Unpacked content. """ # Assume this is enough to detect a Pipeline Response without importing it context = getattr(raw_data, "context", {}) @@ -1579,14 +1673,21 @@ def _unpack_content(raw_data, content_type=None): def _instantiate_model(self, response, attrs, additional_properties=None): """Instantiate a response model passing in deserialized args. - :param response: The response model class. - :param d_attrs: The deserialized response attributes. + :param Response response: The response model class. + :param dict attrs: The deserialized response attributes. + :param dict additional_properties: Additional properties to be set. + :rtype: Response + :return: The instantiated response model. """ if callable(response): subtype = getattr(response, "_subtype_map", {}) try: - readonly = [k for k, v in response._validation.items() if v.get("readonly")] - const = [k for k, v in response._validation.items() if v.get("constant")] + readonly = [ + k for k, v in response._validation.items() if v.get("readonly") # pylint: disable=protected-access + ] + const = [ + k for k, v in response._validation.items() if v.get("constant") # pylint: disable=protected-access + ] kwargs = {k: v for k, v in attrs.items() if k not in subtype and k not in readonly + const} response_obj = response(**kwargs) for attr in readonly: @@ -1596,7 +1697,7 @@ def _instantiate_model(self, response, attrs, additional_properties=None): return response_obj except TypeError as err: msg = "Unable to deserialize {} into model {}. ".format(kwargs, response) # type: ignore - raise DeserializationError(msg + str(err)) + raise DeserializationError(msg + str(err)) from err else: try: for attr, value in attrs.items(): @@ -1605,15 +1706,16 @@ def _instantiate_model(self, response, attrs, additional_properties=None): except Exception as exp: msg = "Unable to populate response model. " msg += "Type: {}, Error: {}".format(type(response), exp) - raise DeserializationError(msg) + raise DeserializationError(msg) from exp - def deserialize_data(self, data, data_type): + def deserialize_data(self, data, data_type): # pylint: disable=too-many-return-statements """Process data for deserialization according to data type. :param str data: The response string to be deserialized. :param str data_type: The type to deserialize to. :raises: DeserializationError if deserialization fails. :return: Deserialized object. + :rtype: object """ if data is None: return data @@ -1627,7 +1729,11 @@ def deserialize_data(self, data, data_type): if isinstance(data, self.deserialize_expected_types.get(data_type, tuple())): return data - is_a_text_parsing_type = lambda x: x not in ["object", "[]", r"{}"] + is_a_text_parsing_type = lambda x: x not in [ # pylint: disable=unnecessary-lambda-assignment + "object", + "[]", + r"{}", + ] if isinstance(data, ET.Element) and is_a_text_parsing_type(data_type) and not data.text: return None data_val = self.deserialize_type[data_type](data) @@ -1647,14 +1753,14 @@ def deserialize_data(self, data, data_type): msg = "Unable to deserialize response data." msg += " Data: {}, {}".format(data, data_type) raise DeserializationError(msg) from err - else: - return self._deserialize(obj_type, data) + return self._deserialize(obj_type, data) def deserialize_iter(self, attr, iter_type): """Deserialize an iterable. :param list attr: Iterable to be deserialized. :param str iter_type: The type of object in the iterable. + :return: Deserialized iterable. :rtype: list """ if attr is None: @@ -1671,6 +1777,7 @@ def deserialize_dict(self, attr, dict_type): :param dict/list attr: Dictionary to be deserialized. Also accepts a list of key, value pairs. :param str dict_type: The object type of the items in the dictionary. + :return: Deserialized dictionary. :rtype: dict """ if isinstance(attr, list): @@ -1681,11 +1788,12 @@ def deserialize_dict(self, attr, dict_type): attr = {el.tag: el.text for el in attr} return {k: self.deserialize_data(v, dict_type) for k, v in attr.items()} - def deserialize_object(self, attr, **kwargs): + def deserialize_object(self, attr, **kwargs): # pylint: disable=too-many-return-statements """Deserialize a generic object. This will be handled as a dictionary. :param dict attr: Dictionary to be deserialized. + :return: Deserialized object. :rtype: dict :raises: TypeError if non-builtin datatype encountered. """ @@ -1720,11 +1828,10 @@ def deserialize_object(self, attr, **kwargs): pass return deserialized - else: - error = "Cannot deserialize generic object with type: " - raise TypeError(error + str(obj_type)) + error = "Cannot deserialize generic object with type: " + raise TypeError(error + str(obj_type)) - def deserialize_basic(self, attr, data_type): + def deserialize_basic(self, attr, data_type): # pylint: disable=too-many-return-statements """Deserialize basic builtin data type from string. Will attempt to convert to str, int, float and bool. This function will also accept '1', '0', 'true' and 'false' as @@ -1732,6 +1839,7 @@ def deserialize_basic(self, attr, data_type): :param str attr: response string to be deserialized. :param str data_type: deserialization data type. + :return: Deserialized basic type. :rtype: str, int, float or bool :raises: TypeError if string format is not valid. """ @@ -1743,24 +1851,23 @@ def deserialize_basic(self, attr, data_type): if data_type == "str": # None or '', node is empty string. return "" - else: - # None or '', node with a strong type is None. - # Don't try to model "empty bool" or "empty int" - return None + # None or '', node with a strong type is None. + # Don't try to model "empty bool" or "empty int" + return None if data_type == "bool": if attr in [True, False, 1, 0]: return bool(attr) - elif isinstance(attr, str): + if isinstance(attr, str): if attr.lower() in ["true", "1"]: return True - elif attr.lower() in ["false", "0"]: + if attr.lower() in ["false", "0"]: return False raise TypeError("Invalid boolean value: {}".format(attr)) if data_type == "str": return self.deserialize_unicode(attr) - return eval(data_type)(attr) # nosec + return eval(data_type)(attr) # nosec # pylint: disable=eval-used @staticmethod def deserialize_unicode(data): @@ -1768,6 +1875,7 @@ def deserialize_unicode(data): as a string. :param str data: response string to be deserialized. + :return: Deserialized string. :rtype: str or unicode """ # We might be here because we have an enum modeled as string, @@ -1781,8 +1889,7 @@ def deserialize_unicode(data): return data except NameError: return str(data) - else: - return str(data) + return str(data) @staticmethod def deserialize_enum(data, enum_obj): @@ -1794,6 +1901,7 @@ def deserialize_enum(data, enum_obj): :param str data: Response string to be deserialized. If this value is None or invalid it will be returned as-is. :param Enum enum_obj: Enum object to deserialize to. + :return: Deserialized enum object. :rtype: Enum """ if isinstance(data, enum_obj) or data is None: @@ -1804,9 +1912,9 @@ def deserialize_enum(data, enum_obj): # Workaround. We might consider remove it in the future. try: return list(enum_obj.__members__.values())[data] - except IndexError: + except IndexError as exc: error = "{!r} is not a valid index for enum {!r}" - raise DeserializationError(error.format(data, enum_obj)) + raise DeserializationError(error.format(data, enum_obj)) from exc try: return enum_obj(str(data)) except ValueError: @@ -1822,6 +1930,7 @@ def deserialize_bytearray(attr): """Deserialize string into bytearray. :param str attr: response string to be deserialized. + :return: Deserialized bytearray :rtype: bytearray :raises: TypeError if string format invalid. """ @@ -1834,6 +1943,7 @@ def deserialize_base64(attr): """Deserialize base64 encoded string into string. :param str attr: response string to be deserialized. + :return: Deserialized base64 string :rtype: bytearray :raises: TypeError if string format invalid. """ @@ -1849,8 +1959,9 @@ def deserialize_decimal(attr): """Deserialize string into Decimal object. :param str attr: response string to be deserialized. - :rtype: Decimal + :return: Deserialized decimal :raises: DeserializationError if string format invalid. + :rtype: decimal """ if isinstance(attr, ET.Element): attr = attr.text @@ -1865,6 +1976,7 @@ def deserialize_long(attr): """Deserialize string into long (Py2) or int (Py3). :param str attr: response string to be deserialized. + :return: Deserialized int :rtype: long or int :raises: ValueError if string format invalid. """ @@ -1877,6 +1989,7 @@ def deserialize_duration(attr): """Deserialize ISO-8601 formatted string into TimeDelta object. :param str attr: response string to be deserialized. + :return: Deserialized duration :rtype: TimeDelta :raises: DeserializationError if string format invalid. """ @@ -1887,14 +2000,14 @@ def deserialize_duration(attr): except (ValueError, OverflowError, AttributeError) as err: msg = "Cannot deserialize duration object." raise DeserializationError(msg) from err - else: - return duration + return duration @staticmethod def deserialize_date(attr): """Deserialize ISO-8601 formatted string into Date object. :param str attr: response string to be deserialized. + :return: Deserialized date :rtype: Date :raises: DeserializationError if string format invalid. """ @@ -1910,6 +2023,7 @@ def deserialize_time(attr): """Deserialize ISO-8601 formatted string into time object. :param str attr: response string to be deserialized. + :return: Deserialized time :rtype: datetime.time :raises: DeserializationError if string format invalid. """ @@ -1924,6 +2038,7 @@ def deserialize_rfc(attr): """Deserialize RFC-1123 formatted string into Datetime object. :param str attr: response string to be deserialized. + :return: Deserialized RFC datetime :rtype: Datetime :raises: DeserializationError if string format invalid. """ @@ -1939,14 +2054,14 @@ def deserialize_rfc(attr): except ValueError as err: msg = "Cannot deserialize to rfc datetime object." raise DeserializationError(msg) from err - else: - return date_obj + return date_obj @staticmethod def deserialize_iso(attr): """Deserialize ISO-8601 formatted string into Datetime object. :param str attr: response string to be deserialized. + :return: Deserialized ISO datetime :rtype: Datetime :raises: DeserializationError if string format invalid. """ @@ -1976,8 +2091,7 @@ def deserialize_iso(attr): except (ValueError, OverflowError, AttributeError) as err: msg = "Cannot deserialize datetime object." raise DeserializationError(msg) from err - else: - return date_obj + return date_obj @staticmethod def deserialize_unix(attr): @@ -1985,6 +2099,7 @@ def deserialize_unix(attr): This is represented as seconds. :param int attr: Object to be serialized. + :return: Deserialized datetime :rtype: Datetime :raises: DeserializationError if format invalid """ @@ -1996,5 +2111,4 @@ def deserialize_unix(attr): except ValueError as err: msg = "Cannot deserialize to unix datetime object." raise DeserializationError(msg) from err - else: - return date_obj + return date_obj diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_version.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_version.py index 48944bf3938a..e5754a47ce68 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_version.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/_version.py @@ -6,4 +6,4 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -VERSION = "2.0.0" +VERSION = "1.0.0b1" diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/__init__.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/__init__.py index 224638cef30a..0a80cf6d1a10 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/__init__.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/__init__.py @@ -5,12 +5,18 @@ # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- +# pylint: disable=wrong-import-position -from ._desktop_virtualization_mgmt_client import DesktopVirtualizationMgmtClient +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from ._patch import * # pylint: disable=unused-wildcard-import + +from ._desktop_virtualization_mgmt_client import DesktopVirtualizationMgmtClient # type: ignore try: from ._patch import __all__ as _patch_all - from ._patch import * # pylint: disable=unused-wildcard-import + from ._patch import * except ImportError: _patch_all = [] from ._patch import patch_sdk as _patch_sdk @@ -18,6 +24,6 @@ __all__ = [ "DesktopVirtualizationMgmtClient", ] -__all__.extend([p for p in _patch_all if p not in __all__]) +__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore _patch_sdk() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_configuration.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_configuration.py index 50ef97143926..33f444f5b98d 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_configuration.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_configuration.py @@ -14,7 +14,6 @@ from .._version import VERSION if TYPE_CHECKING: - # pylint: disable=unused-import,ungrouped-imports from azure.core.credentials_async import AsyncTokenCredential @@ -28,13 +27,13 @@ class DesktopVirtualizationMgmtClientConfiguration: # pylint: disable=too-many- :type credential: ~azure.core.credentials_async.AsyncTokenCredential :param subscription_id: The ID of the target subscription. The value must be an UUID. Required. :type subscription_id: str - :keyword api_version: Api Version. Default value is "2024-04-03". Note that overriding this + :keyword api_version: Api Version. Default value is "2024-09-10". Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str """ def __init__(self, credential: "AsyncTokenCredential", subscription_id: str, **kwargs: Any) -> None: - api_version: str = kwargs.pop("api_version", "2024-04-03") + api_version: str = kwargs.pop("api_version", "2024-09-10") if credential is None: raise ValueError("Parameter 'credential' must not be None.") diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_desktop_virtualization_mgmt_client.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_desktop_virtualization_mgmt_client.py index 459f270b399e..1e800fdff84e 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_desktop_virtualization_mgmt_client.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/_desktop_virtualization_mgmt_client.py @@ -40,11 +40,10 @@ ) if TYPE_CHECKING: - # pylint: disable=unused-import,ungrouped-imports from azure.core.credentials_async import AsyncTokenCredential -class DesktopVirtualizationMgmtClient: # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes +class DesktopVirtualizationMgmtClient: # pylint: disable=too-many-instance-attributes """DesktopVirtualizationMgmtClient. :ivar operations: Operations operations @@ -97,7 +96,7 @@ class DesktopVirtualizationMgmtClient: # pylint: disable=client-accepts-api-ver :type subscription_id: str :param base_url: Service URL. Default value is "https://management.azure.com". :type base_url: str - :keyword api_version: Api Version. Default value is "2024-04-03". Note that overriding this + :keyword api_version: Api Version. Default value is "2024-09-10". Note that overriding this default value may result in unsupported behavior. :paramtype api_version: str """ diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/__init__.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/__init__.py index df927dd95440..c9c5486a2601 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/__init__.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/__init__.py @@ -5,28 +5,34 @@ # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- +# pylint: disable=wrong-import-position -from ._operations import Operations -from ._workspaces_operations import WorkspacesOperations -from ._private_endpoint_connections_operations import PrivateEndpointConnectionsOperations -from ._private_link_resources_operations import PrivateLinkResourcesOperations -from ._scaling_plans_operations import ScalingPlansOperations -from ._scaling_plan_pooled_schedules_operations import ScalingPlanPooledSchedulesOperations -from ._scaling_plan_personal_schedules_operations import ScalingPlanPersonalSchedulesOperations -from ._application_groups_operations import ApplicationGroupsOperations -from ._start_menu_items_operations import StartMenuItemsOperations -from ._applications_operations import ApplicationsOperations -from ._desktops_operations import DesktopsOperations -from ._host_pools_operations import HostPoolsOperations -from ._user_sessions_operations import UserSessionsOperations -from ._session_hosts_operations import SessionHostsOperations -from ._msix_packages_operations import MSIXPackagesOperations -from ._app_attach_package_info_operations import AppAttachPackageInfoOperations -from ._msix_images_operations import MsixImagesOperations -from ._app_attach_package_operations import AppAttachPackageOperations +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from ._patch import * # pylint: disable=unused-wildcard-import + +from ._operations import Operations # type: ignore +from ._workspaces_operations import WorkspacesOperations # type: ignore +from ._private_endpoint_connections_operations import PrivateEndpointConnectionsOperations # type: ignore +from ._private_link_resources_operations import PrivateLinkResourcesOperations # type: ignore +from ._scaling_plans_operations import ScalingPlansOperations # type: ignore +from ._scaling_plan_pooled_schedules_operations import ScalingPlanPooledSchedulesOperations # type: ignore +from ._scaling_plan_personal_schedules_operations import ScalingPlanPersonalSchedulesOperations # type: ignore +from ._application_groups_operations import ApplicationGroupsOperations # type: ignore +from ._start_menu_items_operations import StartMenuItemsOperations # type: ignore +from ._applications_operations import ApplicationsOperations # type: ignore +from ._desktops_operations import DesktopsOperations # type: ignore +from ._host_pools_operations import HostPoolsOperations # type: ignore +from ._user_sessions_operations import UserSessionsOperations # type: ignore +from ._session_hosts_operations import SessionHostsOperations # type: ignore +from ._msix_packages_operations import MSIXPackagesOperations # type: ignore +from ._app_attach_package_info_operations import AppAttachPackageInfoOperations # type: ignore +from ._msix_images_operations import MsixImagesOperations # type: ignore +from ._app_attach_package_operations import AppAttachPackageOperations # type: ignore from ._patch import __all__ as _patch_all -from ._patch import * # pylint: disable=unused-wildcard-import +from ._patch import * from ._patch import patch_sdk as _patch_sdk __all__ = [ @@ -49,5 +55,5 @@ "MsixImagesOperations", "AppAttachPackageOperations", ] -__all__.extend([p for p in _patch_all if p not in __all__]) +__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore _patch_sdk() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_info_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_info_operations.py index 508d45e2de01..822f56747e39 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_info_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_info_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -146,7 +145,7 @@ def import_method( content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) cls: ClsType[_models.AppAttachPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_operations.py index e15d1700b12f..eed8e671f530 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_app_attach_package_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -40,7 +39,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -79,7 +78,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.AppAttachPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -199,7 +198,7 @@ async def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.AppAttachPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -255,9 +254,7 @@ async def create_or_update( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements - self, resource_group_name: str, app_attach_package_name: str, **kwargs: Any - ) -> None: + async def delete(self, resource_group_name: str, app_attach_package_name: str, **kwargs: Any) -> None: """Remove an App Attach Package. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -269,7 +266,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -387,7 +384,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.AppAttachPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -468,7 +465,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.AppAttachPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -551,7 +548,7 @@ def list_by_subscription( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.AppAttachPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_application_groups_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_application_groups_operations.py index 85b9c639ab72..1585cfaffc3c 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_application_groups_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_application_groups_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -40,7 +39,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -79,7 +78,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.ApplicationGroup :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -197,7 +196,7 @@ async def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.ApplicationGroup :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -252,9 +251,7 @@ async def create_or_update( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements - self, resource_group_name: str, application_group_name: str, **kwargs: Any - ) -> None: + async def delete(self, resource_group_name: str, application_group_name: str, **kwargs: Any) -> None: """Remove an applicationGroup. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -266,7 +263,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -383,7 +380,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ApplicationGroup :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -475,7 +472,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ApplicationGroupList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -560,7 +557,7 @@ def list_by_subscription( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ApplicationGroupList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_applications_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_applications_operations.py index d21375e40c45..d4198266e4a1 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_applications_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_applications_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -39,7 +38,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -81,7 +80,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.Application :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -212,7 +211,7 @@ async def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.Application :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -268,7 +267,7 @@ async def create_or_update( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements + async def delete( self, resource_group_name: str, application_group_name: str, application_name: str, **kwargs: Any ) -> None: """Remove an application. @@ -285,7 +284,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -412,7 +411,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.Application :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -504,7 +503,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ApplicationList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_desktops_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_desktops_operations.py index fb1790ae3681..a4ccccf63747 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_desktops_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_desktops_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -33,7 +32,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -74,7 +73,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.Desktop :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -202,7 +201,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.Desktop :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -294,7 +293,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.DesktopList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_host_pools_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_host_pools_operations.py index 6c02ad1f5973..ad1a7d1800ea 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_host_pools_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_host_pools_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -42,7 +41,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -79,7 +78,7 @@ async def get(self, resource_group_name: str, host_pool_name: str, **kwargs: Any :rtype: ~azure.mgmt.desktopvirtualization.models.HostPool :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -197,7 +196,7 @@ async def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.HostPool :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -252,7 +251,7 @@ async def create_or_update( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements + async def delete( self, resource_group_name: str, host_pool_name: str, force: Optional[bool] = None, **kwargs: Any ) -> None: """Remove a host pool. @@ -268,7 +267,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -383,7 +382,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.HostPool :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -471,7 +470,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.HostPoolList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -562,7 +561,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.HostPoolList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -640,7 +639,7 @@ async def retrieve_registration_token( :rtype: ~azure.mgmt.desktopvirtualization.models.RegistrationInfo :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -697,7 +696,7 @@ async def list_registration_tokens( :rtype: ~azure.mgmt.desktopvirtualization.models.RegistrationTokenList :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_images_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_images_operations.py index e773c50662e3..8722050ce74b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_images_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_images_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -142,7 +141,7 @@ def expand( content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) cls: ClsType[_models.ExpandMsixImageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_packages_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_packages_operations.py index 600fd5c5dc8d..82edb5c94e01 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_packages_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_msix_packages_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -39,7 +38,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -81,7 +80,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.MSIXPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -212,7 +211,7 @@ async def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.MSIXPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -268,7 +267,7 @@ async def create_or_update( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements + async def delete( self, resource_group_name: str, host_pool_name: str, msix_package_full_name: str, **kwargs: Any ) -> None: """Remove an MSIX Package. @@ -285,7 +284,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -412,7 +411,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.MSIXPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -504,7 +503,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.MSIXPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_operations.py index c48bca8240e1..9448ea3dbbc6 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -7,7 +6,7 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- import sys -from typing import Any, AsyncIterable, Callable, Dict, Optional, Type, TypeVar +from typing import Any, AsyncIterable, Callable, Dict, Optional, TypeVar import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -31,7 +30,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -71,7 +70,7 @@ def list(self, **kwargs: Any) -> AsyncIterable["_models.ResourceProviderOperatio api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ResourceProviderOperationList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_endpoint_connections_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_endpoint_connections_operations.py index 1a2a1c1208c8..a19536df00fd 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_endpoint_connections_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_endpoint_connections_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -42,7 +41,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -70,6 +69,7 @@ def __init__(self, *args, **kwargs) -> None: def list_by_workspace( self, resource_group_name: str, workspace_name: str, **kwargs: Any ) -> AsyncIterable["_models.PrivateEndpointConnectionWithSystemData"]: + # pylint: disable=line-too-long """List private endpoint connections. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -89,7 +89,7 @@ def list_by_workspace( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateEndpointConnectionListResultWithSystemData] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -169,7 +169,7 @@ async def get_by_workspace( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -213,7 +213,7 @@ async def get_by_workspace( return deserialized # type: ignore @distributed_trace_async - async def delete_by_workspace( # pylint: disable=inconsistent-return-statements + async def delete_by_workspace( self, resource_group_name: str, workspace_name: str, private_endpoint_connection_name: str, **kwargs: Any ) -> None: """Remove a connection. @@ -230,7 +230,7 @@ async def delete_by_workspace( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -358,7 +358,7 @@ async def update_by_workspace( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -423,6 +423,7 @@ def list_by_host_pool( initial_skip: Optional[int] = None, **kwargs: Any ) -> AsyncIterable["_models.PrivateEndpointConnectionWithSystemData"]: + # pylint: disable=line-too-long """List private endpoint connections associated with hostpool. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -448,7 +449,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateEndpointConnectionListResultWithSystemData] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -531,7 +532,7 @@ async def get_by_host_pool( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -575,7 +576,7 @@ async def get_by_host_pool( return deserialized # type: ignore @distributed_trace_async - async def delete_by_host_pool( # pylint: disable=inconsistent-return-statements + async def delete_by_host_pool( self, resource_group_name: str, host_pool_name: str, private_endpoint_connection_name: str, **kwargs: Any ) -> None: """Remove a connection. @@ -592,7 +593,7 @@ async def delete_by_host_pool( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -720,7 +721,7 @@ async def update_by_host_pool( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_link_resources_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_link_resources_operations.py index f47e7e19d506..99546dc3ea8c 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_link_resources_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_private_link_resources_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -7,7 +6,7 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- import sys -from typing import Any, AsyncIterable, Callable, Dict, Optional, Type, TypeVar +from typing import Any, AsyncIterable, Callable, Dict, Optional, TypeVar import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -34,7 +33,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -92,7 +91,7 @@ def list_by_workspace( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateLinkResourceListResult] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -191,7 +190,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateLinkResourceListResult] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_personal_schedules_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_personal_schedules_operations.py index 621c61afe6ed..1c540310c8b6 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_personal_schedules_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_personal_schedules_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -39,7 +38,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -80,7 +79,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPersonalSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -212,7 +211,7 @@ async def create( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPersonalSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -268,7 +267,7 @@ async def create( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements + async def delete( self, resource_group_name: str, scaling_plan_name: str, scaling_plan_schedule_name: str, **kwargs: Any ) -> None: """Remove a ScalingPlanPersonalSchedule. @@ -284,7 +283,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -412,7 +411,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPersonalSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -505,7 +504,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanPersonalScheduleList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_pooled_schedules_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_pooled_schedules_operations.py index 4f2c8e715a3c..c05b8bff6309 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_pooled_schedules_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plan_pooled_schedules_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -39,7 +38,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -80,7 +79,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPooledSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -211,7 +210,7 @@ async def create( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPooledSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -267,7 +266,7 @@ async def create( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements + async def delete( self, resource_group_name: str, scaling_plan_name: str, scaling_plan_schedule_name: str, **kwargs: Any ) -> None: """Remove a ScalingPlanPooledSchedule. @@ -283,7 +282,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -411,7 +410,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPooledSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -504,7 +503,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanPooledScheduleList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plans_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plans_operations.py index 1cdf85e4fd44..add8d84af88f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plans_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_scaling_plans_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -41,7 +40,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -78,7 +77,7 @@ async def get(self, resource_group_name: str, scaling_plan_name: str, **kwargs: :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlan :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -196,7 +195,7 @@ async def create( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlan :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -251,9 +250,7 @@ async def create( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements - self, resource_group_name: str, scaling_plan_name: str, **kwargs: Any - ) -> None: + async def delete(self, resource_group_name: str, scaling_plan_name: str, **kwargs: Any) -> None: """Remove a scaling plan. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -265,7 +262,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -379,7 +376,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlan :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -467,7 +464,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -558,7 +555,7 @@ def list_by_subscription( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -655,7 +652,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_session_hosts_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_session_hosts_operations.py index 55d5d6e8fbf5..71a657d0c55a 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_session_hosts_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_session_hosts_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -38,7 +37,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -80,7 +79,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.SessionHost :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -124,7 +123,7 @@ async def get( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements + async def delete( self, resource_group_name: str, host_pool_name: str, @@ -149,7 +148,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -289,7 +288,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.SessionHost :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -382,7 +381,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.SessionHostList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_start_menu_items_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_start_menu_items_operations.py index ac7671a50014..34a75c5f51ae 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_start_menu_items_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_start_menu_items_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -7,7 +6,7 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- import sys -from typing import Any, AsyncIterable, Callable, Dict, Optional, Type, TypeVar +from typing import Any, AsyncIterable, Callable, Dict, Optional, TypeVar import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -31,7 +30,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -89,7 +88,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.StartMenuItemList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_user_sessions_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_user_sessions_operations.py index 05aeae0749fe..885737ef78ce 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_user_sessions_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_user_sessions_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -40,7 +39,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -102,7 +101,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.UserSessionList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -189,7 +188,7 @@ async def get( :rtype: ~azure.mgmt.desktopvirtualization.models.UserSession :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -234,7 +233,7 @@ async def get( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements + async def delete( self, resource_group_name: str, host_pool_name: str, @@ -262,7 +261,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -341,7 +340,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.UserSessionList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -408,7 +407,7 @@ async def get_next(next_link=None): return AsyncItemPaged(get_next, extract_data) @distributed_trace_async - async def disconnect( # pylint: disable=inconsistent-return-statements + async def disconnect( self, resource_group_name: str, host_pool_name: str, session_host_name: str, user_session_id: str, **kwargs: Any ) -> None: """Disconnect a userSession. @@ -428,7 +427,7 @@ async def disconnect( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -469,7 +468,7 @@ async def disconnect( # pylint: disable=inconsistent-return-statements return cls(pipeline_response, None, {}) # type: ignore @overload - async def send_message( # pylint: disable=inconsistent-return-statements + async def send_message( self, resource_group_name: str, host_pool_name: str, @@ -505,7 +504,7 @@ async def send_message( # pylint: disable=inconsistent-return-statements """ @overload - async def send_message( # pylint: disable=inconsistent-return-statements + async def send_message( self, resource_group_name: str, host_pool_name: str, @@ -541,7 +540,7 @@ async def send_message( # pylint: disable=inconsistent-return-statements """ @distributed_trace_async - async def send_message( # pylint: disable=inconsistent-return-statements + async def send_message( self, resource_group_name: str, host_pool_name: str, @@ -570,7 +569,7 @@ async def send_message( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_workspaces_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_workspaces_operations.py index c75eaf26869a..a9fa9b11ecac 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_workspaces_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/aio/operations/_workspaces_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, Type, TypeVar, Union, overload +from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload import urllib.parse from azure.core.async_paging import AsyncItemPaged, AsyncList @@ -40,7 +39,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]] @@ -77,7 +76,7 @@ async def get(self, resource_group_name: str, workspace_name: str, **kwargs: Any :rtype: ~azure.mgmt.desktopvirtualization.models.Workspace :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -195,7 +194,7 @@ async def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.Workspace :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -250,9 +249,7 @@ async def create_or_update( return deserialized # type: ignore @distributed_trace_async - async def delete( # pylint: disable=inconsistent-return-statements - self, resource_group_name: str, workspace_name: str, **kwargs: Any - ) -> None: + async def delete(self, resource_group_name: str, workspace_name: str, **kwargs: Any) -> None: """Remove a workspace. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -264,7 +261,7 @@ async def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -378,7 +375,7 @@ async def update( :rtype: ~azure.mgmt.desktopvirtualization.models.Workspace :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -466,7 +463,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.WorkspaceList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -545,7 +542,7 @@ def list_by_subscription(self, **kwargs: Any) -> AsyncIterable["_models.Workspac api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.WorkspaceList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/__init__.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/__init__.py index e4e4586e68ad..da2ad1138d27 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/__init__.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/__init__.py @@ -5,132 +5,147 @@ # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- +# pylint: disable=wrong-import-position -from ._models_py3 import AgentUpdatePatchProperties -from ._models_py3 import AgentUpdateProperties -from ._models_py3 import AppAttachPackage -from ._models_py3 import AppAttachPackageInfoProperties -from ._models_py3 import AppAttachPackageList -from ._models_py3 import AppAttachPackagePatch -from ._models_py3 import AppAttachPackagePatchProperties -from ._models_py3 import AppAttachPackageProperties -from ._models_py3 import Application -from ._models_py3 import ApplicationGroup -from ._models_py3 import ApplicationGroupList -from ._models_py3 import ApplicationGroupPatch -from ._models_py3 import ApplicationList -from ._models_py3 import ApplicationPatch -from ._models_py3 import CloudErrorProperties -from ._models_py3 import Desktop -from ._models_py3 import DesktopList -from ._models_py3 import DesktopPatch -from ._models_py3 import ErrorAdditionalInfo -from ._models_py3 import ErrorDetail -from ._models_py3 import ErrorResponse -from ._models_py3 import ExpandMsixImage -from ._models_py3 import ExpandMsixImageList -from ._models_py3 import HostPool -from ._models_py3 import HostPoolList -from ._models_py3 import HostPoolPatch -from ._models_py3 import Identity -from ._models_py3 import ImportPackageInfoRequest -from ._models_py3 import LogSpecification -from ._models_py3 import MSIXImageURI -from ._models_py3 import MSIXPackage -from ._models_py3 import MSIXPackageList -from ._models_py3 import MSIXPackagePatch -from ._models_py3 import MaintenanceWindowPatchProperties -from ._models_py3 import MaintenanceWindowProperties -from ._models_py3 import MsixPackageApplications -from ._models_py3 import MsixPackageDependencies -from ._models_py3 import OperationProperties -from ._models_py3 import Plan -from ._models_py3 import PrivateEndpoint -from ._models_py3 import PrivateEndpointConnection -from ._models_py3 import PrivateEndpointConnectionListResultWithSystemData -from ._models_py3 import PrivateEndpointConnectionWithSystemData -from ._models_py3 import PrivateLinkResource -from ._models_py3 import PrivateLinkResourceListResult -from ._models_py3 import PrivateLinkServiceConnectionState -from ._models_py3 import ProxyResource -from ._models_py3 import RegistrationInfo -from ._models_py3 import RegistrationInfoPatch -from ._models_py3 import RegistrationTokenList -from ._models_py3 import RegistrationTokenMinimal -from ._models_py3 import Resource -from ._models_py3 import ResourceModelWithAllowedPropertySet -from ._models_py3 import ResourceModelWithAllowedPropertySetIdentity -from ._models_py3 import ResourceModelWithAllowedPropertySetPlan -from ._models_py3 import ResourceModelWithAllowedPropertySetSku -from ._models_py3 import ResourceProviderOperation -from ._models_py3 import ResourceProviderOperationDisplay -from ._models_py3 import ResourceProviderOperationList -from ._models_py3 import ScalingHostPoolReference -from ._models_py3 import ScalingPlan -from ._models_py3 import ScalingPlanList -from ._models_py3 import ScalingPlanPatch -from ._models_py3 import ScalingPlanPersonalSchedule -from ._models_py3 import ScalingPlanPersonalScheduleList -from ._models_py3 import ScalingPlanPersonalSchedulePatch -from ._models_py3 import ScalingPlanPooledSchedule -from ._models_py3 import ScalingPlanPooledScheduleList -from ._models_py3 import ScalingPlanPooledSchedulePatch -from ._models_py3 import ScalingSchedule -from ._models_py3 import SendMessage -from ._models_py3 import ServiceSpecification -from ._models_py3 import SessionHost -from ._models_py3 import SessionHostHealthCheckFailureDetails -from ._models_py3 import SessionHostHealthCheckReport -from ._models_py3 import SessionHostList -from ._models_py3 import SessionHostPatch -from ._models_py3 import Sku -from ._models_py3 import StartMenuItem -from ._models_py3 import StartMenuItemList -from ._models_py3 import SystemData -from ._models_py3 import Time -from ._models_py3 import TrackedResource -from ._models_py3 import UserSession -from ._models_py3 import UserSessionList -from ._models_py3 import Workspace -from ._models_py3 import WorkspaceList -from ._models_py3 import WorkspacePatch +from typing import TYPE_CHECKING -from ._desktop_virtualization_mgmt_client_enums import AppAttachPackageArchitectures -from ._desktop_virtualization_mgmt_client_enums import ApplicationGroupType -from ._desktop_virtualization_mgmt_client_enums import ApplicationType -from ._desktop_virtualization_mgmt_client_enums import CommandLineSetting -from ._desktop_virtualization_mgmt_client_enums import CreatedByType -from ._desktop_virtualization_mgmt_client_enums import DayOfWeek -from ._desktop_virtualization_mgmt_client_enums import FailHealthCheckOnStagingFailure -from ._desktop_virtualization_mgmt_client_enums import HealthCheckName -from ._desktop_virtualization_mgmt_client_enums import HealthCheckResult -from ._desktop_virtualization_mgmt_client_enums import HostPoolType -from ._desktop_virtualization_mgmt_client_enums import HostpoolPublicNetworkAccess -from ._desktop_virtualization_mgmt_client_enums import LoadBalancerType -from ._desktop_virtualization_mgmt_client_enums import PackageTimestamped -from ._desktop_virtualization_mgmt_client_enums import PersonalDesktopAssignmentType -from ._desktop_virtualization_mgmt_client_enums import PreferredAppGroupType -from ._desktop_virtualization_mgmt_client_enums import PrivateEndpointConnectionProvisioningState -from ._desktop_virtualization_mgmt_client_enums import PrivateEndpointServiceConnectionStatus -from ._desktop_virtualization_mgmt_client_enums import ProvisioningState -from ._desktop_virtualization_mgmt_client_enums import PublicNetworkAccess -from ._desktop_virtualization_mgmt_client_enums import RegistrationTokenOperation -from ._desktop_virtualization_mgmt_client_enums import RemoteApplicationType -from ._desktop_virtualization_mgmt_client_enums import SSOSecretType -from ._desktop_virtualization_mgmt_client_enums import ScalingHostPoolType -from ._desktop_virtualization_mgmt_client_enums import ScalingScheduleDaysOfWeekItem -from ._desktop_virtualization_mgmt_client_enums import SessionHandlingOperation -from ._desktop_virtualization_mgmt_client_enums import SessionHostComponentUpdateType -from ._desktop_virtualization_mgmt_client_enums import SessionHostLoadBalancingAlgorithm -from ._desktop_virtualization_mgmt_client_enums import SessionState -from ._desktop_virtualization_mgmt_client_enums import SetStartVMOnConnect -from ._desktop_virtualization_mgmt_client_enums import SkuTier -from ._desktop_virtualization_mgmt_client_enums import StartupBehavior -from ._desktop_virtualization_mgmt_client_enums import Status -from ._desktop_virtualization_mgmt_client_enums import StopHostsWhen -from ._desktop_virtualization_mgmt_client_enums import UpdateState +if TYPE_CHECKING: + from ._patch import * # pylint: disable=unused-wildcard-import + + +from ._models_py3 import ( # type: ignore + AgentUpdatePatchProperties, + AgentUpdateProperties, + AppAttachPackage, + AppAttachPackageInfoProperties, + AppAttachPackageList, + AppAttachPackagePatch, + AppAttachPackagePatchProperties, + AppAttachPackageProperties, + Application, + ApplicationGroup, + ApplicationGroupList, + ApplicationGroupPatch, + ApplicationList, + ApplicationPatch, + CloudErrorProperties, + Desktop, + DesktopList, + DesktopPatch, + ErrorAdditionalInfo, + ErrorDetail, + ErrorResponse, + ExpandMsixImage, + ExpandMsixImageList, + HostPool, + HostPoolList, + HostPoolPatch, + Identity, + ImportPackageInfoRequest, + LogSpecification, + MSIXImageURI, + MSIXPackage, + MSIXPackageList, + MSIXPackagePatch, + MaintenanceWindowPatchProperties, + MaintenanceWindowProperties, + MsixPackageApplications, + MsixPackageDependencies, + OperationProperties, + Plan, + PrivateEndpoint, + PrivateEndpointConnection, + PrivateEndpointConnectionListResultWithSystemData, + PrivateEndpointConnectionWithSystemData, + PrivateLinkResource, + PrivateLinkResourceListResult, + PrivateLinkServiceConnectionState, + ProxyResource, + RegistrationInfo, + RegistrationInfoPatch, + RegistrationTokenList, + RegistrationTokenMinimal, + Resource, + ResourceModelWithAllowedPropertySet, + ResourceModelWithAllowedPropertySetIdentity, + ResourceModelWithAllowedPropertySetPlan, + ResourceModelWithAllowedPropertySetSku, + ResourceProviderOperation, + ResourceProviderOperationDisplay, + ResourceProviderOperationList, + ScalingHostPoolReference, + ScalingPlan, + ScalingPlanList, + ScalingPlanPatch, + ScalingPlanPersonalSchedule, + ScalingPlanPersonalScheduleList, + ScalingPlanPersonalSchedulePatch, + ScalingPlanPooledSchedule, + ScalingPlanPooledScheduleList, + ScalingPlanPooledSchedulePatch, + ScalingSchedule, + SendMessage, + ServiceSpecification, + SessionHost, + SessionHostHealthCheckFailureDetails, + SessionHostHealthCheckReport, + SessionHostList, + SessionHostPatch, + Sku, + StartMenuItem, + StartMenuItemList, + SystemData, + Time, + TrackedResource, + UserSession, + UserSessionList, + Workspace, + WorkspaceList, + WorkspacePatch, +) + +from ._desktop_virtualization_mgmt_client_enums import ( # type: ignore + AppAttachPackageArchitectures, + ApplicationGroupType, + ApplicationType, + CommandLineSetting, + CreatedByType, + DayOfWeek, + DirectUDP, + FailHealthCheckOnStagingFailure, + HealthCheckName, + HealthCheckResult, + HostPoolType, + HostpoolPublicNetworkAccess, + LoadBalancerType, + ManagedPrivateUDP, + PackageTimestamped, + PersonalDesktopAssignmentType, + PreferredAppGroupType, + PrivateEndpointConnectionProvisioningState, + PrivateEndpointServiceConnectionStatus, + ProvisioningState, + PublicNetworkAccess, + PublicUDP, + RegistrationTokenOperation, + RelayUDP, + RemoteApplicationType, + SSOSecretType, + ScalingHostPoolType, + ScalingScheduleDaysOfWeekItem, + SessionHandlingOperation, + SessionHostComponentUpdateType, + SessionHostLoadBalancingAlgorithm, + SessionState, + SetStartVMOnConnect, + SkuTier, + StartupBehavior, + Status, + StopHostsWhen, + UpdateState, +) from ._patch import __all__ as _patch_all -from ._patch import * # pylint: disable=unused-wildcard-import +from ._patch import * from ._patch import patch_sdk as _patch_sdk __all__ = [ @@ -228,12 +243,14 @@ "CommandLineSetting", "CreatedByType", "DayOfWeek", + "DirectUDP", "FailHealthCheckOnStagingFailure", "HealthCheckName", "HealthCheckResult", "HostPoolType", "HostpoolPublicNetworkAccess", "LoadBalancerType", + "ManagedPrivateUDP", "PackageTimestamped", "PersonalDesktopAssignmentType", "PreferredAppGroupType", @@ -241,7 +258,9 @@ "PrivateEndpointServiceConnectionStatus", "ProvisioningState", "PublicNetworkAccess", + "PublicUDP", "RegistrationTokenOperation", + "RelayUDP", "RemoteApplicationType", "SSOSecretType", "ScalingHostPoolType", @@ -257,5 +276,5 @@ "StopHostsWhen", "UpdateState", ] -__all__.extend([p for p in _patch_all if p not in __all__]) +__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore _patch_sdk() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_desktop_virtualization_mgmt_client_enums.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_desktop_virtualization_mgmt_client_enums.py index 81bb4af5b02b..33bc56a59c93 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_desktop_virtualization_mgmt_client_enums.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_desktop_virtualization_mgmt_client_enums.py @@ -68,6 +68,18 @@ class DayOfWeek(str, Enum, metaclass=CaseInsensitiveEnumMeta): SUNDAY = "Sunday" +class DirectUDP(str, Enum, metaclass=CaseInsensitiveEnumMeta): + """Default: AVD-wide settings are used to determine connection availability, Enabled: UDP will + attempt this connection type when making connections. This means that this connection is + possible, but is not guaranteed, as there are other factors that may prevent this connection + type, Disabled: UDP will not attempt this connection type when making connections. + """ + + DEFAULT = "Default" + ENABLED = "Enabled" + DISABLED = "Disabled" + + class FailHealthCheckOnStagingFailure(str, Enum, metaclass=CaseInsensitiveEnumMeta): """Parameter indicating how the health check should behave if this package fails staging.""" @@ -179,6 +191,18 @@ class LoadBalancerType(str, Enum, metaclass=CaseInsensitiveEnumMeta): PERSISTENT = "Persistent" +class ManagedPrivateUDP(str, Enum, metaclass=CaseInsensitiveEnumMeta): + """Default: AVD-wide settings are used to determine connection availability, Enabled: UDP will + attempt this connection type when making connections. This means that this connection is + possible, but is not guaranteed, as there are other factors that may prevent this connection + type, Disabled: UDP will not attempt this connection type when making connections. + """ + + DEFAULT = "Default" + ENABLED = "Enabled" + DISABLED = "Disabled" + + class PackageTimestamped(str, Enum, metaclass=CaseInsensitiveEnumMeta): """Is package timestamped so it can ignore the certificate expiry date.""" @@ -236,6 +260,18 @@ class PublicNetworkAccess(str, Enum, metaclass=CaseInsensitiveEnumMeta): DISABLED = "Disabled" +class PublicUDP(str, Enum, metaclass=CaseInsensitiveEnumMeta): + """Default: AVD-wide settings are used to determine connection availability, Enabled: UDP will + attempt this connection type when making connections. This means that this connection is + possible, but is not guaranteed, as there are other factors that may prevent this connection + type, Disabled: UDP will not attempt this connection type when making connections. + """ + + DEFAULT = "Default" + ENABLED = "Enabled" + DISABLED = "Disabled" + + class RegistrationTokenOperation(str, Enum, metaclass=CaseInsensitiveEnumMeta): """The type of resetting the token.""" @@ -244,6 +280,18 @@ class RegistrationTokenOperation(str, Enum, metaclass=CaseInsensitiveEnumMeta): UPDATE = "Update" +class RelayUDP(str, Enum, metaclass=CaseInsensitiveEnumMeta): + """Default: AVD-wide settings are used to determine connection availability, Enabled: UDP will + attempt this connection type when making connections. This means that this connection is + possible, but is not guaranteed, as there are other factors that may prevent this connection + type, Disabled: UDP will not attempt this connection type when making connections. + """ + + DEFAULT = "Default" + ENABLED = "Enabled" + DISABLED = "Disabled" + + class RemoteApplicationType(str, Enum, metaclass=CaseInsensitiveEnumMeta): """Resource Type of Application.""" diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_models_py3.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_models_py3.py index fa56640fb1de..4920429726b0 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_models_py3.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/models/_models_py3.py @@ -1,5 +1,5 @@ -# coding=utf-8 # pylint: disable=too-many-lines +# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. @@ -13,7 +13,6 @@ from .. import _serialization if TYPE_CHECKING: - # pylint: disable=unused-import,ungrouped-imports from .. import models as _models @@ -287,7 +286,7 @@ def __init__( self.properties = properties -class AppAttachPackageInfoProperties(_serialization.Model): # pylint: disable=too-many-instance-attributes +class AppAttachPackageInfoProperties(_serialization.Model): """Schema for Import Package Information properties. :ivar package_alias: Alias of App Attach Package. Assigned at import time. @@ -618,7 +617,7 @@ def __init__( self.fail_health_check_on_staging_failure = fail_health_check_on_staging_failure -class Application(Resource): # pylint: disable=too-many-instance-attributes +class Application(Resource): """Schema for Application properties. Variables are only populated by the server, and will be ignored when sending a request. @@ -770,7 +769,7 @@ def __init__( self.icon_content = None -class ResourceModelWithAllowedPropertySet(TrackedResource): # pylint: disable=too-many-instance-attributes +class ResourceModelWithAllowedPropertySet(TrackedResource): """The resource model definition containing the full set of allowed properties for a resource. Except properties bag, there cannot be a top level property outside of this set. @@ -886,7 +885,7 @@ def __init__( self.plan = plan -class ApplicationGroup(ResourceModelWithAllowedPropertySet): # pylint: disable=too-many-instance-attributes +class ApplicationGroup(ResourceModelWithAllowedPropertySet): """Represents a ApplicationGroup definition. Variables are only populated by the server, and will be ignored when sending a request. @@ -1190,7 +1189,7 @@ def __init__(self, *, value: Optional[List["_models.Application"]] = None, **kwa self.next_link = None -class ApplicationPatch(_serialization.Model): # pylint: disable=too-many-instance-attributes +class ApplicationPatch(_serialization.Model): """Application properties that can be patched. :ivar tags: tags to be updated. @@ -1561,7 +1560,7 @@ def __init__(self, *, error: Optional["_models.ErrorDetail"] = None, **kwargs: A self.error = error -class ExpandMsixImage(Resource): # pylint: disable=too-many-instance-attributes +class ExpandMsixImage(Resource): """Represents the definition of contents retrieved after expanding the MSIX Image. Variables are only populated by the server, and will be ignored when sending a request. @@ -1744,7 +1743,7 @@ def __init__(self, *, value: Optional[List["_models.ExpandMsixImage"]] = None, * self.next_link = None -class HostPool(ResourceModelWithAllowedPropertySet): # pylint: disable=too-many-instance-attributes +class HostPool(ResourceModelWithAllowedPropertySet): """Represents a HostPool definition. Variables are only populated by the server, and will be ignored when sending a request. @@ -1853,6 +1852,30 @@ class HostPool(ResourceModelWithAllowedPropertySet): # pylint: disable=too-many specified resource. :vartype private_endpoint_connections: list[~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnection] + :ivar managed_private_udp: Default: AVD-wide settings are used to determine connection + availability, Enabled: UDP will attempt this connection type when making connections. This + means that this connection is possible, but is not guaranteed, as there are other factors that + may prevent this connection type, Disabled: UDP will not attempt this connection type when + making connections. Known values are: "Default", "Enabled", and "Disabled". + :vartype managed_private_udp: str or ~azure.mgmt.desktopvirtualization.models.ManagedPrivateUDP + :ivar direct_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :vartype direct_udp: str or ~azure.mgmt.desktopvirtualization.models.DirectUDP + :ivar public_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :vartype public_udp: str or ~azure.mgmt.desktopvirtualization.models.PublicUDP + :ivar relay_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :vartype relay_udp: str or ~azure.mgmt.desktopvirtualization.models.RelayUDP """ _validation = { @@ -1913,6 +1936,10 @@ class HostPool(ResourceModelWithAllowedPropertySet): # pylint: disable=too-many "key": "properties.privateEndpointConnections", "type": "[PrivateEndpointConnection]", }, + "managed_private_udp": {"key": "properties.managedPrivateUDP", "type": "str"}, + "direct_udp": {"key": "properties.directUDP", "type": "str"}, + "public_udp": {"key": "properties.publicUDP", "type": "str"}, + "relay_udp": {"key": "properties.relayUDP", "type": "str"}, } def __init__( # pylint: disable=too-many-locals @@ -1944,6 +1971,10 @@ def __init__( # pylint: disable=too-many-locals start_vm_on_connect: Optional[bool] = None, public_network_access: Optional[Union[str, "_models.HostpoolPublicNetworkAccess"]] = None, agent_update: Optional["_models.AgentUpdateProperties"] = None, + managed_private_udp: Optional[Union[str, "_models.ManagedPrivateUDP"]] = None, + direct_udp: Optional[Union[str, "_models.DirectUDP"]] = None, + public_udp: Optional[Union[str, "_models.PublicUDP"]] = None, + relay_udp: Optional[Union[str, "_models.RelayUDP"]] = None, **kwargs: Any ) -> None: """ @@ -2021,6 +2052,31 @@ def __init__( # pylint: disable=too-many-locals :keyword agent_update: The session host configuration for updating agent, monitoring agent, and stack component. :paramtype agent_update: ~azure.mgmt.desktopvirtualization.models.AgentUpdateProperties + :keyword managed_private_udp: Default: AVD-wide settings are used to determine connection + availability, Enabled: UDP will attempt this connection type when making connections. This + means that this connection is possible, but is not guaranteed, as there are other factors that + may prevent this connection type, Disabled: UDP will not attempt this connection type when + making connections. Known values are: "Default", "Enabled", and "Disabled". + :paramtype managed_private_udp: str or + ~azure.mgmt.desktopvirtualization.models.ManagedPrivateUDP + :keyword direct_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :paramtype direct_udp: str or ~azure.mgmt.desktopvirtualization.models.DirectUDP + :keyword public_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :paramtype public_udp: str or ~azure.mgmt.desktopvirtualization.models.PublicUDP + :keyword relay_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :paramtype relay_udp: str or ~azure.mgmt.desktopvirtualization.models.RelayUDP """ super().__init__( tags=tags, @@ -2056,6 +2112,10 @@ def __init__( # pylint: disable=too-many-locals self.public_network_access = public_network_access self.agent_update = agent_update self.private_endpoint_connections = None + self.managed_private_udp = managed_private_udp + self.direct_udp = direct_udp + self.public_udp = public_udp + self.relay_udp = relay_udp class HostPoolList(_serialization.Model): @@ -2088,7 +2148,7 @@ def __init__(self, *, value: Optional[List["_models.HostPool"]] = None, **kwargs self.next_link = None -class HostPoolPatch(Resource): # pylint: disable=too-many-instance-attributes +class HostPoolPatch(Resource): """HostPool properties that can be patched. Variables are only populated by the server, and will be ignored when sending a request. @@ -2154,6 +2214,30 @@ class HostPoolPatch(Resource): # pylint: disable=too-many-instance-attributes :ivar agent_update: The session host configuration for updating agent, monitoring agent, and stack component. :vartype agent_update: ~azure.mgmt.desktopvirtualization.models.AgentUpdatePatchProperties + :ivar managed_private_udp: Default: AVD-wide settings are used to determine connection + availability, Enabled: UDP will attempt this connection type when making connections. This + means that this connection is possible, but is not guaranteed, as there are other factors that + may prevent this connection type, Disabled: UDP will not attempt this connection type when + making connections. Known values are: "Default", "Enabled", and "Disabled". + :vartype managed_private_udp: str or ~azure.mgmt.desktopvirtualization.models.ManagedPrivateUDP + :ivar direct_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :vartype direct_udp: str or ~azure.mgmt.desktopvirtualization.models.DirectUDP + :ivar public_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :vartype public_udp: str or ~azure.mgmt.desktopvirtualization.models.PublicUDP + :ivar relay_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :vartype relay_udp: str or ~azure.mgmt.desktopvirtualization.models.RelayUDP """ _validation = { @@ -2187,9 +2271,13 @@ class HostPoolPatch(Resource): # pylint: disable=too-many-instance-attributes "start_vm_on_connect": {"key": "properties.startVMOnConnect", "type": "bool"}, "public_network_access": {"key": "properties.publicNetworkAccess", "type": "str"}, "agent_update": {"key": "properties.agentUpdate", "type": "AgentUpdatePatchProperties"}, + "managed_private_udp": {"key": "properties.managedPrivateUDP", "type": "str"}, + "direct_udp": {"key": "properties.directUDP", "type": "str"}, + "public_udp": {"key": "properties.publicUDP", "type": "str"}, + "relay_udp": {"key": "properties.relayUDP", "type": "str"}, } - def __init__( + def __init__( # pylint: disable=too-many-locals self, *, tags: Optional[Dict[str, str]] = None, @@ -2211,6 +2299,10 @@ def __init__( start_vm_on_connect: Optional[bool] = None, public_network_access: Optional[Union[str, "_models.HostpoolPublicNetworkAccess"]] = None, agent_update: Optional["_models.AgentUpdatePatchProperties"] = None, + managed_private_udp: Optional[Union[str, "_models.ManagedPrivateUDP"]] = None, + direct_udp: Optional[Union[str, "_models.DirectUDP"]] = None, + public_udp: Optional[Union[str, "_models.PublicUDP"]] = None, + relay_udp: Optional[Union[str, "_models.RelayUDP"]] = None, **kwargs: Any ) -> None: """ @@ -2264,6 +2356,31 @@ def __init__( :keyword agent_update: The session host configuration for updating agent, monitoring agent, and stack component. :paramtype agent_update: ~azure.mgmt.desktopvirtualization.models.AgentUpdatePatchProperties + :keyword managed_private_udp: Default: AVD-wide settings are used to determine connection + availability, Enabled: UDP will attempt this connection type when making connections. This + means that this connection is possible, but is not guaranteed, as there are other factors that + may prevent this connection type, Disabled: UDP will not attempt this connection type when + making connections. Known values are: "Default", "Enabled", and "Disabled". + :paramtype managed_private_udp: str or + ~azure.mgmt.desktopvirtualization.models.ManagedPrivateUDP + :keyword direct_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :paramtype direct_udp: str or ~azure.mgmt.desktopvirtualization.models.DirectUDP + :keyword public_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :paramtype public_udp: str or ~azure.mgmt.desktopvirtualization.models.PublicUDP + :keyword relay_udp: Default: AVD-wide settings are used to determine connection availability, + Enabled: UDP will attempt this connection type when making connections. This means that this + connection is possible, but is not guaranteed, as there are other factors that may prevent this + connection type, Disabled: UDP will not attempt this connection type when making connections. + Known values are: "Default", "Enabled", and "Disabled". + :paramtype relay_udp: str or ~azure.mgmt.desktopvirtualization.models.RelayUDP """ super().__init__(**kwargs) self.tags = tags @@ -2285,6 +2402,10 @@ def __init__( self.start_vm_on_connect = start_vm_on_connect self.public_network_access = public_network_access self.agent_update = agent_update + self.managed_private_udp = managed_private_udp + self.direct_udp = direct_udp + self.public_udp = public_udp + self.relay_udp = relay_udp class Identity(_serialization.Model): @@ -2485,7 +2606,7 @@ def __init__(self, *, uri: Optional[str] = None, **kwargs: Any) -> None: self.uri = uri -class MSIXPackage(Resource): # pylint: disable=too-many-instance-attributes +class MSIXPackage(Resource): """Schema for MSIX Package properties. Variables are only populated by the server, and will be ignored when sending a request. @@ -3627,7 +3748,7 @@ def __init__( self.scaling_plan_enabled = scaling_plan_enabled -class ScalingPlan(ResourceModelWithAllowedPropertySet): # pylint: disable=too-many-instance-attributes +class ScalingPlan(ResourceModelWithAllowedPropertySet): """Represents a scaling plan definition. Variables are only populated by the server, and will be ignored when sending a request. @@ -3901,7 +4022,7 @@ def __init__( self.host_pool_references = host_pool_references -class ScalingPlanPersonalSchedule(ProxyResource): # pylint: disable=too-many-instance-attributes +class ScalingPlanPersonalSchedule(ProxyResource): """Represents a ScalingPlanPersonalSchedule definition. Variables are only populated by the server, and will be ignored when sending a request. @@ -4236,7 +4357,7 @@ def __init__(self, *, value: Optional[List["_models.ScalingPlanPersonalSchedule" self.next_link = None -class ScalingPlanPersonalSchedulePatch(_serialization.Model): # pylint: disable=too-many-instance-attributes +class ScalingPlanPersonalSchedulePatch(_serialization.Model): """ScalingPlanPersonalSchedule properties that can be patched. :ivar days_of_week: Set of days of the week on which this schedule is active. @@ -4520,7 +4641,7 @@ def __init__( # pylint: disable=too-many-locals self.off_peak_minutes_to_wait_on_logoff = off_peak_minutes_to_wait_on_logoff -class ScalingPlanPooledSchedule(Resource): # pylint: disable=too-many-instance-attributes +class ScalingPlanPooledSchedule(Resource): """Represents a ScalingPlanPooledSchedule definition. Variables are only populated by the server, and will be ignored when sending a request. @@ -4738,7 +4859,7 @@ def __init__(self, *, value: Optional[List["_models.ScalingPlanPooledSchedule"]] self.next_link = None -class ScalingPlanPooledSchedulePatch(Resource): # pylint: disable=too-many-instance-attributes +class ScalingPlanPooledSchedulePatch(Resource): """ScalingPlanPooledSchedule properties that can be patched. Variables are only populated by the server, and will be ignored when sending a request. @@ -4926,7 +5047,7 @@ def __init__( self.off_peak_load_balancing_algorithm = off_peak_load_balancing_algorithm -class ScalingSchedule(_serialization.Model): # pylint: disable=too-many-instance-attributes +class ScalingSchedule(_serialization.Model): """A ScalingPlanPooledSchedule. :ivar name: Name of the ScalingPlanPooledSchedule. @@ -5150,7 +5271,7 @@ def __init__(self, *, log_specifications: Optional[List["_models.LogSpecificatio self.log_specifications = log_specifications -class SessionHost(Resource): # pylint: disable=too-many-instance-attributes +class SessionHost(Resource): """Represents a SessionHost definition. Variables are only populated by the server, and will be ignored when sending a request. @@ -5799,7 +5920,7 @@ def __init__(self, *, value: Optional[List["_models.UserSession"]] = None, **kwa self.next_link = None -class Workspace(ResourceModelWithAllowedPropertySet): # pylint: disable=too-many-instance-attributes +class Workspace(ResourceModelWithAllowedPropertySet): """Represents a Workspace definition. Variables are only populated by the server, and will be ignored when sending a request. diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/__init__.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/__init__.py index df927dd95440..c9c5486a2601 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/__init__.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/__init__.py @@ -5,28 +5,34 @@ # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- +# pylint: disable=wrong-import-position -from ._operations import Operations -from ._workspaces_operations import WorkspacesOperations -from ._private_endpoint_connections_operations import PrivateEndpointConnectionsOperations -from ._private_link_resources_operations import PrivateLinkResourcesOperations -from ._scaling_plans_operations import ScalingPlansOperations -from ._scaling_plan_pooled_schedules_operations import ScalingPlanPooledSchedulesOperations -from ._scaling_plan_personal_schedules_operations import ScalingPlanPersonalSchedulesOperations -from ._application_groups_operations import ApplicationGroupsOperations -from ._start_menu_items_operations import StartMenuItemsOperations -from ._applications_operations import ApplicationsOperations -from ._desktops_operations import DesktopsOperations -from ._host_pools_operations import HostPoolsOperations -from ._user_sessions_operations import UserSessionsOperations -from ._session_hosts_operations import SessionHostsOperations -from ._msix_packages_operations import MSIXPackagesOperations -from ._app_attach_package_info_operations import AppAttachPackageInfoOperations -from ._msix_images_operations import MsixImagesOperations -from ._app_attach_package_operations import AppAttachPackageOperations +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from ._patch import * # pylint: disable=unused-wildcard-import + +from ._operations import Operations # type: ignore +from ._workspaces_operations import WorkspacesOperations # type: ignore +from ._private_endpoint_connections_operations import PrivateEndpointConnectionsOperations # type: ignore +from ._private_link_resources_operations import PrivateLinkResourcesOperations # type: ignore +from ._scaling_plans_operations import ScalingPlansOperations # type: ignore +from ._scaling_plan_pooled_schedules_operations import ScalingPlanPooledSchedulesOperations # type: ignore +from ._scaling_plan_personal_schedules_operations import ScalingPlanPersonalSchedulesOperations # type: ignore +from ._application_groups_operations import ApplicationGroupsOperations # type: ignore +from ._start_menu_items_operations import StartMenuItemsOperations # type: ignore +from ._applications_operations import ApplicationsOperations # type: ignore +from ._desktops_operations import DesktopsOperations # type: ignore +from ._host_pools_operations import HostPoolsOperations # type: ignore +from ._user_sessions_operations import UserSessionsOperations # type: ignore +from ._session_hosts_operations import SessionHostsOperations # type: ignore +from ._msix_packages_operations import MSIXPackagesOperations # type: ignore +from ._app_attach_package_info_operations import AppAttachPackageInfoOperations # type: ignore +from ._msix_images_operations import MsixImagesOperations # type: ignore +from ._app_attach_package_operations import AppAttachPackageOperations # type: ignore from ._patch import __all__ as _patch_all -from ._patch import * # pylint: disable=unused-wildcard-import +from ._patch import * from ._patch import patch_sdk as _patch_sdk __all__ = [ @@ -49,5 +55,5 @@ "MsixImagesOperations", "AppAttachPackageOperations", ] -__all__.extend([p for p in _patch_all if p not in __all__]) +__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore _patch_sdk() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_info_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_info_operations.py index 077e07be9440..637261a44446 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_info_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_info_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_import_method_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -184,7 +183,7 @@ def import_method( content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) cls: ClsType[_models.AppAttachPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_operations.py index a6b06fb591c3..df4bf5ac057a 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_app_attach_package_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -86,7 +85,7 @@ def build_create_or_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -129,7 +128,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -169,7 +168,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -212,7 +211,7 @@ def build_list_by_resource_group_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -246,7 +245,7 @@ def build_list_by_subscription_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -302,7 +301,7 @@ def get(self, resource_group_name: str, app_attach_package_name: str, **kwargs: :rtype: ~azure.mgmt.desktopvirtualization.models.AppAttachPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -422,7 +421,7 @@ def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.AppAttachPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -492,7 +491,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -610,7 +609,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.AppAttachPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -690,7 +689,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.AppAttachPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -770,7 +769,7 @@ def list_by_subscription(self, filter: Optional[str] = None, **kwargs: Any) -> I api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.AppAttachPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_application_groups_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_application_groups_operations.py index 870748fdddd9..6d229f035b24 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_application_groups_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_application_groups_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -86,7 +85,7 @@ def build_create_or_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -129,7 +128,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -169,7 +168,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -219,7 +218,7 @@ def build_list_by_resource_group_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -259,7 +258,7 @@ def build_list_by_subscription_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -315,7 +314,7 @@ def get(self, resource_group_name: str, application_group_name: str, **kwargs: A :rtype: ~azure.mgmt.desktopvirtualization.models.ApplicationGroup :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -433,7 +432,7 @@ def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.ApplicationGroup :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -502,7 +501,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -619,7 +618,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ApplicationGroup :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -710,7 +709,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ApplicationGroupList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -792,7 +791,7 @@ def list_by_subscription(self, filter: Optional[str] = None, **kwargs: Any) -> I api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ApplicationGroupList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_applications_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_applications_operations.py index 0d9e753eab88..a044cf8c5e39 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_applications_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_applications_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -89,7 +88,7 @@ def build_create_or_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -135,7 +134,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -178,7 +177,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -231,7 +230,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -308,7 +307,7 @@ def get( :rtype: ~azure.mgmt.desktopvirtualization.models.Application :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -439,7 +438,7 @@ def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.Application :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -512,7 +511,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -639,7 +638,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.Application :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -730,7 +729,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ApplicationList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_desktops_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_desktops_operations.py index 7504de7951ce..6bbe9f38c607 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_desktops_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_desktops_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -89,7 +88,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -142,7 +141,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -218,7 +217,7 @@ def get( :rtype: ~azure.mgmt.desktopvirtualization.models.Desktop :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -346,7 +345,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.Desktop :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -437,7 +436,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.DesktopList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_host_pools_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_host_pools_operations.py index fbd4a0b1da44..b0dee303cfd0 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_host_pools_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_host_pools_operations.py @@ -1,4 +1,4 @@ -# pylint: disable=too-many-lines,too-many-statements +# pylint: disable=too-many-lines # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +8,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +32,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +46,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -81,7 +81,7 @@ def build_create_or_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -119,7 +119,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -156,7 +156,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -200,7 +200,7 @@ def build_list_by_resource_group_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -243,7 +243,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -277,7 +277,7 @@ def build_retrieve_registration_token_request( # pylint: disable=name-too-long _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -312,7 +312,7 @@ def build_list_registration_tokens_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -373,7 +373,7 @@ def get(self, resource_group_name: str, host_pool_name: str, **kwargs: Any) -> _ :rtype: ~azure.mgmt.desktopvirtualization.models.HostPool :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -491,7 +491,7 @@ def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.HostPool :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -562,7 +562,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -677,7 +677,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.HostPool :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -764,7 +764,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.HostPoolList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -854,7 +854,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.HostPoolList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -932,7 +932,7 @@ def retrieve_registration_token( :rtype: ~azure.mgmt.desktopvirtualization.models.RegistrationInfo :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -989,7 +989,7 @@ def list_registration_tokens( :rtype: ~azure.mgmt.desktopvirtualization.models.RegistrationTokenList :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_images_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_images_operations.py index a602ef61d945..706f38edb97f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_images_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_images_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_expand_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -180,7 +179,7 @@ def expand( content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) cls: ClsType[_models.ExpandMsixImageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_packages_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_packages_operations.py index 645fa353dc5c..8f417ab8a163 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_packages_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_msix_packages_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -89,7 +88,7 @@ def build_create_or_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -135,7 +134,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -178,7 +177,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -231,7 +230,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -303,7 +302,7 @@ def get( :rtype: ~azure.mgmt.desktopvirtualization.models.MSIXPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -434,7 +433,7 @@ def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.MSIXPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -507,7 +506,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -634,7 +633,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.MSIXPackage :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -725,7 +724,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.MSIXPackageList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_operations.py index 066c8cf26276..1f9952f5959f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -7,7 +6,7 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- import sys -from typing import Any, Callable, Dict, Iterable, Optional, Type, TypeVar +from typing import Any, Callable, Dict, Iterable, Optional, TypeVar import urllib.parse from azure.core.exceptions import ( @@ -31,7 +30,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -43,7 +42,7 @@ def build_list_request(**kwargs: Any) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -93,7 +92,7 @@ def list(self, **kwargs: Any) -> Iterable["_models.ResourceProviderOperation"]: api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ResourceProviderOperationList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_endpoint_connections_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_endpoint_connections_operations.py index 723ac5e2b192..c749a8600ac5 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_endpoint_connections_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_endpoint_connections_operations.py @@ -1,4 +1,4 @@ -# pylint: disable=too-many-lines,too-many-statements +# pylint: disable=too-many-lines # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +8,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +32,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +46,7 @@ def build_list_by_workspace_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -85,7 +85,7 @@ def build_get_by_workspace_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -127,7 +127,7 @@ def build_delete_by_workspace_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -169,7 +169,7 @@ def build_update_by_workspace_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -217,7 +217,7 @@ def build_list_by_host_pool_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -262,7 +262,7 @@ def build_get_by_host_pool_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -304,7 +304,7 @@ def build_delete_by_host_pool_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -346,7 +346,7 @@ def build_update_by_host_pool_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -423,7 +423,7 @@ def list_by_workspace( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateEndpointConnectionListResultWithSystemData] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -503,7 +503,7 @@ def get_by_workspace( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -564,7 +564,7 @@ def delete_by_workspace( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -692,7 +692,7 @@ def update_by_workspace( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -782,7 +782,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateEndpointConnectionListResultWithSystemData] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -865,7 +865,7 @@ def get_by_host_pool( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -926,7 +926,7 @@ def delete_by_host_pool( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -1054,7 +1054,7 @@ def update_by_host_pool( :rtype: ~azure.mgmt.desktopvirtualization.models.PrivateEndpointConnectionWithSystemData :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_link_resources_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_link_resources_operations.py index 29d187f3a69e..358556a02d1b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_link_resources_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_private_link_resources_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -7,7 +6,7 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- import sys -from typing import Any, Callable, Dict, Iterable, Optional, Type, TypeVar +from typing import Any, Callable, Dict, Iterable, Optional, TypeVar import urllib.parse from azure.core.exceptions import ( @@ -31,7 +30,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -52,7 +51,7 @@ def build_list_by_workspace_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -100,7 +99,7 @@ def build_list_by_host_pool_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -188,7 +187,7 @@ def list_by_workspace( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateLinkResourceListResult] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -287,7 +286,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.PrivateLinkResourceListResult] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_personal_schedules_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_personal_schedules_operations.py index a28ff48dc5a4..273978e188b3 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_personal_schedules_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_personal_schedules_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -50,7 +49,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -97,7 +96,7 @@ def build_create_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -147,7 +146,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -194,7 +193,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -247,7 +246,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -318,7 +317,7 @@ def get( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPersonalSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -450,7 +449,7 @@ def create( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPersonalSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -522,7 +521,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -650,7 +649,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPersonalSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -743,7 +742,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanPersonalScheduleList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_pooled_schedules_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_pooled_schedules_operations.py index 272f08869c78..0fedc41125d9 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_pooled_schedules_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plan_pooled_schedules_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -50,7 +49,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -97,7 +96,7 @@ def build_create_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -147,7 +146,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -194,7 +193,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -247,7 +246,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -318,7 +317,7 @@ def get( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPooledSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -449,7 +448,7 @@ def create( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPooledSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -521,7 +520,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -649,7 +648,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlanPooledSchedule :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -742,7 +741,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanPooledScheduleList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plans_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plans_operations.py index 96cb4dae6d9d..19845e2a7c99 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plans_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_scaling_plans_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -81,7 +80,7 @@ def build_create_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -119,7 +118,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -154,7 +153,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -198,7 +197,7 @@ def build_list_by_resource_group_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -241,7 +240,7 @@ def build_list_by_subscription_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -282,7 +281,7 @@ def build_list_by_host_pool_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -349,7 +348,7 @@ def get(self, resource_group_name: str, scaling_plan_name: str, **kwargs: Any) - :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlan :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -467,7 +466,7 @@ def create( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlan :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -536,7 +535,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -650,7 +649,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.ScalingPlan :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -737,7 +736,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -827,7 +826,7 @@ def list_by_subscription( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -923,7 +922,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.ScalingPlanList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_session_hosts_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_session_hosts_operations.py index a13604cb1569..92fe929a5ae3 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_session_hosts_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_session_hosts_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -90,7 +89,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -136,7 +135,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -186,7 +185,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -258,7 +257,7 @@ def get( :rtype: ~azure.mgmt.desktopvirtualization.models.SessionHost :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -327,7 +326,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -467,7 +466,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.SessionHost :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -559,7 +558,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.SessionHostList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_start_menu_items_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_start_menu_items_operations.py index 5ff91168d267..79eff2079fec 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_start_menu_items_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_start_menu_items_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -7,7 +6,7 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- import sys -from typing import Any, Callable, Dict, Iterable, Optional, Type, TypeVar +from typing import Any, Callable, Dict, Iterable, Optional, TypeVar import urllib.parse from azure.core.exceptions import ( @@ -31,7 +30,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -52,7 +51,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -144,7 +143,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.StartMenuItemList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_user_sessions_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_user_sessions_operations.py index a551f43645f9..eceda374f5a6 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_user_sessions_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_user_sessions_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -54,7 +53,7 @@ def build_list_by_host_pool_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -102,7 +101,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -148,7 +147,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -197,7 +196,7 @@ def build_list_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -246,7 +245,7 @@ def build_disconnect_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -290,7 +289,7 @@ def build_send_message_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -382,7 +381,7 @@ def list_by_host_pool( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.UserSessionList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -469,7 +468,7 @@ def get( :rtype: ~azure.mgmt.desktopvirtualization.models.UserSession :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -542,7 +541,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -620,7 +619,7 @@ def list( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.UserSessionList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -707,7 +706,7 @@ def disconnect( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -748,7 +747,7 @@ def disconnect( # pylint: disable=inconsistent-return-statements return cls(pipeline_response, None, {}) # type: ignore @overload - def send_message( # pylint: disable=inconsistent-return-statements + def send_message( self, resource_group_name: str, host_pool_name: str, @@ -784,7 +783,7 @@ def send_message( # pylint: disable=inconsistent-return-statements """ @overload - def send_message( # pylint: disable=inconsistent-return-statements + def send_message( self, resource_group_name: str, host_pool_name: str, @@ -849,7 +848,7 @@ def send_message( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_workspaces_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_workspaces_operations.py index 94b8a7955f8e..602f0d404244 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_workspaces_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/azure/mgmt/desktopvirtualization/operations/_workspaces_operations.py @@ -1,4 +1,3 @@ -# pylint: disable=too-many-lines,too-many-statements # coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. @@ -8,7 +7,7 @@ # -------------------------------------------------------------------------- from io import IOBase import sys -from typing import Any, Callable, Dict, IO, Iterable, Optional, Type, TypeVar, Union, overload +from typing import Any, Callable, Dict, IO, Iterable, Optional, TypeVar, Union, overload import urllib.parse from azure.core.exceptions import ( @@ -32,7 +31,7 @@ if sys.version_info >= (3, 9): from collections.abc import MutableMapping else: - from typing import MutableMapping # type: ignore # pylint: disable=ungrouped-imports + from typing import MutableMapping # type: ignore T = TypeVar("T") ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] @@ -46,7 +45,7 @@ def build_get_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -81,7 +80,7 @@ def build_create_or_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -119,7 +118,7 @@ def build_delete_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -154,7 +153,7 @@ def build_update_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None)) accept = _headers.pop("Accept", "application/json") @@ -198,7 +197,7 @@ def build_list_by_resource_group_request( _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -234,7 +233,7 @@ def build_list_by_subscription_request(subscription_id: str, **kwargs: Any) -> H _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) - api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-04-03")) + api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2024-09-10")) accept = _headers.pop("Accept", "application/json") # Construct URL @@ -288,7 +287,7 @@ def get(self, resource_group_name: str, workspace_name: str, **kwargs: Any) -> _ :rtype: ~azure.mgmt.desktopvirtualization.models.Workspace :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -406,7 +405,7 @@ def create_or_update( :rtype: ~azure.mgmt.desktopvirtualization.models.Workspace :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -475,7 +474,7 @@ def delete( # pylint: disable=inconsistent-return-statements :rtype: None :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -589,7 +588,7 @@ def update( :rtype: ~azure.mgmt.desktopvirtualization.models.Workspace :raises ~azure.core.exceptions.HttpResponseError: """ - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -676,7 +675,7 @@ def list_by_resource_group( api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.WorkspaceList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, @@ -754,7 +753,7 @@ def list_by_subscription(self, **kwargs: Any) -> Iterable["_models.Workspace"]: api_version: str = kwargs.pop("api_version", _params.pop("api-version", self._config.api_version)) cls: ClsType[_models.WorkspaceList] = kwargs.pop("cls", None) - error_map: MutableMapping[int, Type[HttpResponseError]] = { + error_map: MutableMapping = { 401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError, diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_create.py index 1a3d9fc1eb08..048e63056fa2 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_create.py @@ -78,6 +78,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/AppAttachPackage_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/AppAttachPackage_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_delete.py index dbae419122ab..2317a2c83619 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_delete.py @@ -36,6 +36,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/AppAttachPackage_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/AppAttachPackage_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_get.py index d3306b7757cc..b071583d0fc9 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_get.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/AppAttachPackage_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/AppAttachPackage_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_info_import_post.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_info_import_post.py index 2c297780686a..0cbc8bfd0678 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_info_import_post.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_info_import_post.py @@ -39,6 +39,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/AppAttachPackageInfo_Import_Post.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/AppAttachPackageInfo_Import_Post.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_resource_group.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_resource_group.py index 3bfdde166329..8f4c99be96fa 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_resource_group.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_resource_group.py @@ -37,6 +37,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/AppAttachPackage_ListByResourceGroup.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/AppAttachPackage_ListByResourceGroup.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_subscription.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_subscription.py index fb648e62a071..7d066adf37aa 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_subscription.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_list_by_subscription.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/AppAttachPackage_ListBySubscription.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/AppAttachPackage_ListBySubscription.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_update.py index 0b1239001f98..3bfa424c45ab 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/app_attach_package_update.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/AppAttachPackage_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/AppAttachPackage_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_create.py index 0e99c30581fb..8bba292ad736 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_create.py @@ -50,6 +50,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Application_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Application_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_delete.py index 849f2aadaafb..2247ab29fb32 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_delete.py @@ -37,6 +37,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Application_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Application_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_get.py index 1ea6ce092768..456b5b50d6ab 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_get.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Application_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Application_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_create.py index 95aff0aff571..ce2a270cd341 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_create.py @@ -48,6 +48,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ApplicationGroup_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ApplicationGroup_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_delete.py index 22df1d08fa55..727bc57e2731 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_delete.py @@ -36,6 +36,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ApplicationGroup_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ApplicationGroup_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_get.py index 25c26db4e667..35a1d6c5816b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_get.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ApplicationGroup_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ApplicationGroup_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_resource_group.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_resource_group.py index 0f30342aa9f3..a130efcbbba4 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_resource_group.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_resource_group.py @@ -37,6 +37,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ApplicationGroup_ListByResourceGroup.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ApplicationGroup_ListByResourceGroup.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_subscription.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_subscription.py index 514eaf021932..6856def19e08 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_subscription.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_list_by_subscription.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ApplicationGroup_ListBySubscription.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ApplicationGroup_ListBySubscription.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_update.py index a618dce1d629..7b9b32b94d9d 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_group_update.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ApplicationGroup_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ApplicationGroup_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_list.py index 0c964e1fbb90..6d30934f5f3d 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_list.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Application_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Application_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_update.py index 1a5f906da636..24e980717302 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/application_update.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Application_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Application_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_get.py index 18b47790ea7d..8333758f1284 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_get.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Desktop_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Desktop_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_list.py index 753ecea64156..7faf3517eeb4 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_list.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Desktop_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Desktop_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_update.py index b358a4f54be6..8b074117982f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/desktop_update.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Desktop_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Desktop_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_create.py index 1da2cef16c77..f1fc29d3cc2a 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_create.py @@ -44,16 +44,20 @@ def main(): }, "customRdpProperty": None, "description": "des1", + "directUDP": "Enabled", "friendlyName": "friendly", "hostPoolType": "Pooled", "loadBalancerType": "BreadthFirst", + "managedPrivateUDP": "Enabled", "maxSessionLimit": 999999, "personalDesktopAssignmentType": "Automatic", "preferredAppGroupType": "Desktop", + "publicUDP": "Enabled", "registrationInfo": { "expirationTime": "2020-10-01T14:01:54.9571247Z", "registrationTokenOperation": "Update", }, + "relayUDP": "Enabled", "ssoClientId": "client", "ssoClientSecretKeyVaultPath": "https://keyvault/secret", "ssoSecretType": "SharedKey", @@ -67,6 +71,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPool_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPool_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_delete.py index c35977b4394e..2aeab0bb89f6 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_delete.py @@ -36,6 +36,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPool_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPool_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_get.py index bfc0c17fe097..d08c26521ca1 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_get.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPool_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPool_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list.py index aa25e869679a..77d8d2dc6335 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPool_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPool_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list_by_resource_group.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list_by_resource_group.py index 50c8e0015963..573e97281086 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list_by_resource_group.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_list_by_resource_group.py @@ -37,6 +37,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPool_ListByResourceGroup.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPool_ListByResourceGroup.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_update.py index df9f0ded78f4..e09cd4f597ce 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pool_update.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPool_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPool_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_list_registration_token_post.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_list_registration_token_post.py index b808f45751fe..e40bab1ea6d6 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_list_registration_token_post.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_list_registration_token_post.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPools_ListRegistrationToken_Post.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPools_ListRegistrationToken_Post.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_retrieve_registration_token_post.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_retrieve_registration_token_post.py index a46f233a7b41..3bf173f98b38 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_retrieve_registration_token_post.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/host_pools_retrieve_registration_token_post.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/HostPools_RetrieveRegistrationToken_Post.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/HostPools_RetrieveRegistrationToken_Post.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_create.py index b3d1ee6faf49..3236c24dd5f7 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_create.py @@ -69,6 +69,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/MsixPackage_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/MsixPackage_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_delete.py index 35396a87ea47..e46041133319 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_delete.py @@ -37,6 +37,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/MsixPackage_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/MsixPackage_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_get.py index 122d3ac8bc1a..c550c6aa4e4a 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_get.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/MsixPackage_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/MsixPackage_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_list.py index bdf2b76e629d..1194f32ee9fb 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_list.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/MsixPackage_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/MsixPackage_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_update.py index 816aede3d0d0..d3fdef8f6648 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/msix_package_update.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/MsixPackage_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/MsixPackage_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/operation_description_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/operation_description_list.py index 7ba9404dee7d..bb7ba66f5037 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/operation_description_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/operation_description_list.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/OperationDescription_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/OperationDescription_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_host_pool.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_host_pool.py index ee41840691d3..917dcb3db581 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_host_pool.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_host_pool.py @@ -37,6 +37,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_DeleteByHostPool.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_DeleteByHostPool.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_workspace.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_workspace.py index 15a006caf960..000284199b0b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_workspace.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_delete_by_workspace.py @@ -37,6 +37,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_DeleteByWorkspace.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_DeleteByWorkspace.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_host_pool.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_host_pool.py index f8660d4b0a81..5d0d9b494d65 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_host_pool.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_host_pool.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_GetByHostPool.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_GetByHostPool.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_workspace.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_workspace.py index f9b0589a2b64..e5f32dc0020d 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_workspace.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_get_by_workspace.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_GetByWorkspace.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_GetByWorkspace.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_host_pool.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_host_pool.py index 6d5201a27ce5..0cc33750ed50 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_host_pool.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_host_pool.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_ListByHostPool.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_ListByHostPool.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_workspace.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_workspace.py index 6c41ad8e1512..44aef2709d0f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_workspace.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_list_by_workspace.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_ListByWorkspace.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_ListByWorkspace.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_host_pool.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_host_pool.py index 5b17bbde82ed..efe0aa525c72 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_host_pool.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_host_pool.py @@ -47,6 +47,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_UpdateByHostPool.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_UpdateByHostPool.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_workspace.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_workspace.py index 8a10de65dfa8..9b900147d3fa 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_workspace.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_endpoint_connection_update_by_workspace.py @@ -47,6 +47,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateEndpointConnection_UpdateByWorkspace.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateEndpointConnection_UpdateByWorkspace.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_host_pool.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_host_pool.py index 9374072152e6..ba03ff08e8fa 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_host_pool.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_host_pool.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateLinkResources_ListByHostPool.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateLinkResources_ListByHostPool.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_workspace.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_workspace.py index da8ec5caceee..215bd3528ebf 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_workspace.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/private_link_resources_list_by_workspace.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/PrivateLinkResources_ListByWorkspace.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/PrivateLinkResources_ListByWorkspace.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_create.py index 2ccfc35fb645..eb80acfae300 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_create.py @@ -75,6 +75,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlan_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlan_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_delete.py index f627b071de76..3b1848865a13 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_delete.py @@ -36,6 +36,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlan_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlan_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_get.py index b40c90aa5902..3415b3fef82d 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_get.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlan_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlan_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_host_pool.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_host_pool.py index c3635c78f0da..f583c262dfac 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_host_pool.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_host_pool.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlan_ListByHostPool.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlan_ListByHostPool.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_resource_group.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_resource_group.py index b92cc80c5a82..ffbaae9f32e3 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_resource_group.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_resource_group.py @@ -37,6 +37,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlan_ListByResourceGroup.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlan_ListByResourceGroup.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_subscription.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_subscription.py index b08092ed37bb..066c20fcf2e8 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_subscription.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_list_by_subscription.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlan_ListBySubscription.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlan_ListBySubscription.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_create.py index 4055e6b7e02b..c834d9f55351 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_create.py @@ -68,6 +68,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPersonalSchedule_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPersonalSchedule_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_delete.py index 77b4b85fa9a1..9ea2a9239ead 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_delete.py @@ -37,6 +37,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPersonalSchedule_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPersonalSchedule_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_get.py index 14d7e4d9b927..44a635ba1f14 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_get.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPersonalSchedule_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPersonalSchedule_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_list.py index a1f7eb130178..6bbbbea2b603 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_list.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPersonalSchedule_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPersonalSchedule_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_update.py index ce57fd0e33db..c966d324bfde 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_personal_schedule_update.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPersonalSchedule_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPersonalSchedule_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_create.py index c02ca159aaed..689e97e10a10 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_create.py @@ -58,6 +58,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPooledSchedule_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPooledSchedule_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_delete.py index f2d90dec35c5..68706a13803b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_delete.py @@ -37,6 +37,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPooledSchedule_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPooledSchedule_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_get.py index da2a627f4692..99bcd888f495 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_get.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPooledSchedule_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPooledSchedule_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_list.py index 82033bd51b3a..2e355a921bb7 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_list.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPooledSchedule_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPooledSchedule_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_update.py index cf4ad0c45745..a0d8f1fe6e60 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_pooled_schedule_update.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlanPooledSchedule_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlanPooledSchedule_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_update.py index ec6e2d3e7eaf..037c7dffe2a7 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/scaling_plan_update.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/ScalingPlan_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/ScalingPlan_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_delete.py index 37aaf96a7d31..67717769d353 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_delete.py @@ -37,6 +37,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/SessionHost_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/SessionHost_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_get.py index cd1a39e42ce4..c28affc252cb 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_get.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/SessionHost_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/SessionHost_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_list.py index 59df6423ee56..250e9873f6ba 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_list.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/SessionHost_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/SessionHost_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_update.py index 66a906828b50..63c984f108a3 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/session_host_update.py @@ -38,6 +38,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/SessionHost_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/SessionHost_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/start_menu_item_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/start_menu_item_list.py index 3947795d4bc0..5775a0fd1502 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/start_menu_item_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/start_menu_item_list.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/StartMenuItem_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/StartMenuItem_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_delete.py index 9795cd6b3ea7..8504a402973a 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_delete.py @@ -38,6 +38,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/UserSession_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/UserSession_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_disconnect_post.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_disconnect_post.py index 56a22a9a2d33..c7b96e0fe59e 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_disconnect_post.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_disconnect_post.py @@ -38,6 +38,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/UserSession_Disconnect_Post.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/UserSession_Disconnect_Post.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_get.py index 1c2dd0b04134..92a583a717c6 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_get.py @@ -39,6 +39,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/UserSession_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/UserSession_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list.py index 37e3dff31c75..755d65782d33 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list.py @@ -39,6 +39,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/UserSession_List.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/UserSession_List.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list_by_host_pool.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list_by_host_pool.py index 7ece20e47752..39a024ac44fb 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list_by_host_pool.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_list_by_host_pool.py @@ -38,6 +38,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/UserSession_ListByHostPool.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/UserSession_ListByHostPool.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_send_message_post.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_send_message_post.py index f3f3889c48e4..9cd6249dbecc 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_send_message_post.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/user_session_send_message_post.py @@ -38,6 +38,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/UserSession_SendMessage_Post.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/UserSession_SendMessage_Post.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_create.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_create.py index 3d2e16c4b669..e173715f72fb 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_create.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_create.py @@ -42,6 +42,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Workspace_Create.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Workspace_Create.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_delete.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_delete.py index 8c8f3f1bc584..f50d2c76c7d7 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_delete.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_delete.py @@ -36,6 +36,6 @@ def main(): ) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Workspace_Delete.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Workspace_Delete.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_get.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_get.py index 32696811908c..ced81534db4b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_get.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_get.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Workspace_Get.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Workspace_Get.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_resource_group.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_resource_group.py index c9341a79edc5..9d291c2a0e3d 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_resource_group.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_resource_group.py @@ -37,6 +37,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Workspace_ListByResourceGroup.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Workspace_ListByResourceGroup.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_subscription.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_subscription.py index c21d95f4c0ee..59297e85bc0c 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_subscription.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_list_by_subscription.py @@ -35,6 +35,6 @@ def main(): print(item) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Workspace_ListBySubscription.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Workspace_ListBySubscription.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_update.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_update.py index ad8e24ed16eb..ea8006174749 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_update.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_samples/workspace_update.py @@ -37,6 +37,6 @@ def main(): print(response) -# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-04-03/examples/Workspace_Update.json +# x-ms-original-file: specification/desktopvirtualization/resource-manager/Microsoft.DesktopVirtualization/stable/2024-09-10/examples/Workspace_Update.json if __name__ == "__main__": main() diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/conftest.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/conftest.py index 2bacd7394e96..b919673dd65c 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/conftest.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/conftest.py @@ -18,7 +18,7 @@ load_dotenv() -# aovid record sensitive identity information in recordings +# For security, please avoid record sensitive identity information in recordings @pytest.fixture(scope="session", autouse=True) def add_sanitizers(test_proxy): desktopvirtualizationmgmt_subscription_id = os.environ.get( diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations.py index c5eae9ca9116..1320610c3c04 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_import_method(self, resource_group): + def test_app_attach_package_info_import_method(self, resource_group): response = self.client.app_attach_package_info.import_method( resource_group_name=resource_group.name, host_pool_name="str", import_package_info_request={"packageArchitecture": "str", "path": "str"}, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations_async.py index 381ce67c0991..d4e905cc462f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_info_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_import_method(self, resource_group): + async def test_app_attach_package_info_import_method(self, resource_group): response = self.client.app_attach_package_info.import_method( resource_group_name=resource_group.name, host_pool_name="str", import_package_info_request={"packageArchitecture": "str", "path": "str"}, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations.py index 2714c590f452..889bcf0f3b93 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_app_attach_package_get(self, resource_group): response = self.client.app_attach_package.get( resource_group_name=resource_group.name, app_attach_package_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -32,7 +32,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create_or_update(self, resource_group): + def test_app_attach_package_create_or_update(self, resource_group): response = self.client.app_attach_package.create_or_update( resource_group_name=resource_group.name, app_attach_package_name="str", @@ -85,7 +85,7 @@ def test_create_or_update(self, resource_group): "tags": {"str": "str"}, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -93,11 +93,11 @@ def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_app_attach_package_delete(self, resource_group): response = self.client.app_attach_package.delete( resource_group_name=resource_group.name, app_attach_package_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -105,11 +105,11 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_app_attach_package_update(self, resource_group): response = self.client.app_attach_package.update( resource_group_name=resource_group.name, app_attach_package_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -117,10 +117,10 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_resource_group(self, resource_group): + def test_app_attach_package_list_by_resource_group(self, resource_group): response = self.client.app_attach_package.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -128,9 +128,9 @@ def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_subscription(self, resource_group): + def test_app_attach_package_list_by_subscription(self, resource_group): response = self.client.app_attach_package.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations_async.py index fd872a32f0a4..e0ad0ad3181f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_app_attach_package_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_app_attach_package_get(self, resource_group): response = await self.client.app_attach_package.get( resource_group_name=resource_group.name, app_attach_package_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create_or_update(self, resource_group): + async def test_app_attach_package_create_or_update(self, resource_group): response = await self.client.app_attach_package.create_or_update( resource_group_name=resource_group.name, app_attach_package_name="str", @@ -86,7 +86,7 @@ async def test_create_or_update(self, resource_group): "tags": {"str": "str"}, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -94,11 +94,11 @@ async def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_app_attach_package_delete(self, resource_group): response = await self.client.app_attach_package.delete( resource_group_name=resource_group.name, app_attach_package_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -106,11 +106,11 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_app_attach_package_update(self, resource_group): response = await self.client.app_attach_package.update( resource_group_name=resource_group.name, app_attach_package_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -118,10 +118,10 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_resource_group(self, resource_group): + async def test_app_attach_package_list_by_resource_group(self, resource_group): response = self.client.app_attach_package.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -129,9 +129,9 @@ async def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_subscription(self, resource_group): + async def test_app_attach_package_list_by_subscription(self, resource_group): response = self.client.app_attach_package.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations.py index d1193ef29383..1cabff6218e4 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_application_groups_get(self, resource_group): response = self.client.application_groups.get( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -32,7 +32,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create_or_update(self, resource_group): + def test_application_groups_create_or_update(self, resource_group): response = self.client.application_groups.create_or_update( resource_group_name=resource_group.name, application_group_name="str", @@ -65,7 +65,7 @@ def test_create_or_update(self, resource_group): "type": "str", "workspaceArmPath": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -73,11 +73,11 @@ def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_application_groups_delete(self, resource_group): response = self.client.application_groups.delete( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -85,11 +85,11 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_application_groups_update(self, resource_group): response = self.client.application_groups.update( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -97,10 +97,10 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_resource_group(self, resource_group): + def test_application_groups_list_by_resource_group(self, resource_group): response = self.client.application_groups.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -108,9 +108,9 @@ def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_subscription(self, resource_group): + def test_application_groups_list_by_subscription(self, resource_group): response = self.client.application_groups.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations_async.py index 9f61dc9eeea4..1aecd7ded13e 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_application_groups_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_application_groups_get(self, resource_group): response = await self.client.application_groups.get( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create_or_update(self, resource_group): + async def test_application_groups_create_or_update(self, resource_group): response = await self.client.application_groups.create_or_update( resource_group_name=resource_group.name, application_group_name="str", @@ -66,7 +66,7 @@ async def test_create_or_update(self, resource_group): "type": "str", "workspaceArmPath": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -74,11 +74,11 @@ async def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_application_groups_delete(self, resource_group): response = await self.client.application_groups.delete( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -86,11 +86,11 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_application_groups_update(self, resource_group): response = await self.client.application_groups.update( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -98,10 +98,10 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_resource_group(self, resource_group): + async def test_application_groups_list_by_resource_group(self, resource_group): response = self.client.application_groups.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -109,9 +109,9 @@ async def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_subscription(self, resource_group): + async def test_application_groups_list_by_subscription(self, resource_group): response = self.client.application_groups.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations.py index c5e68ba8dec0..c776fd1d929f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_applications_get(self, resource_group): response = self.client.applications.get( resource_group_name=resource_group.name, application_group_name="str", application_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create_or_update(self, resource_group): + def test_applications_create_or_update(self, resource_group): response = self.client.applications.create_or_update( resource_group_name=resource_group.name, application_group_name="str", @@ -65,7 +65,7 @@ def test_create_or_update(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -73,12 +73,12 @@ def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_applications_delete(self, resource_group): response = self.client.applications.delete( resource_group_name=resource_group.name, application_group_name="str", application_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -86,12 +86,12 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_applications_update(self, resource_group): response = self.client.applications.update( resource_group_name=resource_group.name, application_group_name="str", application_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -99,11 +99,11 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_applications_list(self, resource_group): response = self.client.applications.list( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations_async.py index 1490dbd499c1..e0caf218deb4 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_applications_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_applications_get(self, resource_group): response = await self.client.applications.get( resource_group_name=resource_group.name, application_group_name="str", application_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -34,7 +34,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create_or_update(self, resource_group): + async def test_applications_create_or_update(self, resource_group): response = await self.client.applications.create_or_update( resource_group_name=resource_group.name, application_group_name="str", @@ -66,7 +66,7 @@ async def test_create_or_update(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -74,12 +74,12 @@ async def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_applications_delete(self, resource_group): response = await self.client.applications.delete( resource_group_name=resource_group.name, application_group_name="str", application_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -87,12 +87,12 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_applications_update(self, resource_group): response = await self.client.applications.update( resource_group_name=resource_group.name, application_group_name="str", application_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -100,11 +100,11 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_applications_list(self, resource_group): response = self.client.applications.list( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations.py index 3f5ea7c08f41..26c2da24ee0d 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_desktops_get(self, resource_group): response = self.client.desktops.get( resource_group_name=resource_group.name, application_group_name="str", desktop_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,12 +33,12 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_desktops_update(self, resource_group): response = self.client.desktops.update( resource_group_name=resource_group.name, application_group_name="str", desktop_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -46,11 +46,11 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_desktops_list(self, resource_group): response = self.client.desktops.list( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations_async.py index 76f5dff1b61a..8362f45a10ef 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_desktops_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_desktops_get(self, resource_group): response = await self.client.desktops.get( resource_group_name=resource_group.name, application_group_name="str", desktop_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -34,12 +34,12 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_desktops_update(self, resource_group): response = await self.client.desktops.update( resource_group_name=resource_group.name, application_group_name="str", desktop_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -47,11 +47,11 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_desktops_list(self, resource_group): response = self.client.desktops.list( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations.py index 73087acdd2ba..92a8a190916e 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_host_pools_get(self, resource_group): response = self.client.host_pools.get( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -32,7 +32,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create_or_update(self, resource_group): + def test_host_pools_create_or_update(self, resource_group): response = self.client.host_pools.create_or_update( resource_group_name=resource_group.name, host_pool_name="str", @@ -52,12 +52,14 @@ def test_create_or_update(self, resource_group): "cloudPcResource": bool, "customRdpProperty": "str", "description": "str", + "directUDP": "str", "etag": "str", "friendlyName": "str", "id": "str", "identity": {"principalId": "str", "tenantId": "str", "type": "SystemAssigned"}, "kind": "str", "managedBy": "str", + "managedPrivateUDP": "str", "maxSessionLimit": 0, "name": "str", "objectId": "str", @@ -87,11 +89,13 @@ def test_create_or_update(self, resource_group): } ], "publicNetworkAccess": "str", + "publicUDP": "str", "registrationInfo": { "expirationTime": "2020-02-20 00:00:00", "registrationTokenOperation": "str", "token": "str", }, + "relayUDP": "str", "ring": 0, "sku": {"name": "str", "capacity": 0, "family": "str", "size": "str", "tier": "str"}, "ssoClientId": "str", @@ -112,7 +116,7 @@ def test_create_or_update(self, resource_group): "validationEnvironment": bool, "vmTemplate": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -120,11 +124,11 @@ def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_host_pools_delete(self, resource_group): response = self.client.host_pools.delete( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -132,11 +136,11 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_host_pools_update(self, resource_group): response = self.client.host_pools.update( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -144,10 +148,10 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_resource_group(self, resource_group): + def test_host_pools_list_by_resource_group(self, resource_group): response = self.client.host_pools.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -155,9 +159,9 @@ def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_host_pools_list(self, resource_group): response = self.client.host_pools.list( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -165,11 +169,11 @@ def test_list(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_retrieve_registration_token(self, resource_group): + def test_host_pools_retrieve_registration_token(self, resource_group): response = self.client.host_pools.retrieve_registration_token( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -177,11 +181,11 @@ def test_retrieve_registration_token(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_registration_tokens(self, resource_group): + def test_host_pools_list_registration_tokens(self, resource_group): response = self.client.host_pools.list_registration_tokens( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations_async.py index 4433fbe943d4..ed65166de88f 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_host_pools_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_host_pools_get(self, resource_group): response = await self.client.host_pools.get( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create_or_update(self, resource_group): + async def test_host_pools_create_or_update(self, resource_group): response = await self.client.host_pools.create_or_update( resource_group_name=resource_group.name, host_pool_name="str", @@ -53,12 +53,14 @@ async def test_create_or_update(self, resource_group): "cloudPcResource": bool, "customRdpProperty": "str", "description": "str", + "directUDP": "str", "etag": "str", "friendlyName": "str", "id": "str", "identity": {"principalId": "str", "tenantId": "str", "type": "SystemAssigned"}, "kind": "str", "managedBy": "str", + "managedPrivateUDP": "str", "maxSessionLimit": 0, "name": "str", "objectId": "str", @@ -88,11 +90,13 @@ async def test_create_or_update(self, resource_group): } ], "publicNetworkAccess": "str", + "publicUDP": "str", "registrationInfo": { "expirationTime": "2020-02-20 00:00:00", "registrationTokenOperation": "str", "token": "str", }, + "relayUDP": "str", "ring": 0, "sku": {"name": "str", "capacity": 0, "family": "str", "size": "str", "tier": "str"}, "ssoClientId": "str", @@ -113,7 +117,7 @@ async def test_create_or_update(self, resource_group): "validationEnvironment": bool, "vmTemplate": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -121,11 +125,11 @@ async def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_host_pools_delete(self, resource_group): response = await self.client.host_pools.delete( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -133,11 +137,11 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_host_pools_update(self, resource_group): response = await self.client.host_pools.update( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -145,10 +149,10 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_resource_group(self, resource_group): + async def test_host_pools_list_by_resource_group(self, resource_group): response = self.client.host_pools.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -156,9 +160,9 @@ async def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_host_pools_list(self, resource_group): response = self.client.host_pools.list( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -166,11 +170,11 @@ async def test_list(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_retrieve_registration_token(self, resource_group): + async def test_host_pools_retrieve_registration_token(self, resource_group): response = await self.client.host_pools.retrieve_registration_token( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -178,11 +182,11 @@ async def test_retrieve_registration_token(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_registration_tokens(self, resource_group): + async def test_host_pools_list_registration_tokens(self, resource_group): response = await self.client.host_pools.list_registration_tokens( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations.py index e78b749b217e..400129fc24e1 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_expand(self, resource_group): + def test_msix_images_expand(self, resource_group): response = self.client.msix_images.expand( resource_group_name=resource_group.name, host_pool_name="str", msix_image_uri={"uri": "str"}, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations_async.py index 05b1c49cf285..561d3c38fb07 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_images_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_expand(self, resource_group): + async def test_msix_images_expand(self, resource_group): response = self.client.msix_images.expand( resource_group_name=resource_group.name, host_pool_name="str", msix_image_uri={"uri": "str"}, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations.py index a1f949c00531..febd7eed64f1 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_msix_packages_get(self, resource_group): response = self.client.msix_packages.get( resource_group_name=resource_group.name, host_pool_name="str", msix_package_full_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create_or_update(self, resource_group): + def test_msix_packages_create_or_update(self, resource_group): response = self.client.msix_packages.create_or_update( resource_group_name=resource_group.name, host_pool_name="str", @@ -72,7 +72,7 @@ def test_create_or_update(self, resource_group): "type": "str", "version": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -80,12 +80,12 @@ def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_msix_packages_delete(self, resource_group): response = self.client.msix_packages.delete( resource_group_name=resource_group.name, host_pool_name="str", msix_package_full_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -93,12 +93,12 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_msix_packages_update(self, resource_group): response = self.client.msix_packages.update( resource_group_name=resource_group.name, host_pool_name="str", msix_package_full_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -106,11 +106,11 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_msix_packages_list(self, resource_group): response = self.client.msix_packages.list( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations_async.py index 5a015587b120..bc6ef0beaaf3 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_msix_packages_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_msix_packages_get(self, resource_group): response = await self.client.msix_packages.get( resource_group_name=resource_group.name, host_pool_name="str", msix_package_full_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -34,7 +34,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create_or_update(self, resource_group): + async def test_msix_packages_create_or_update(self, resource_group): response = await self.client.msix_packages.create_or_update( resource_group_name=resource_group.name, host_pool_name="str", @@ -73,7 +73,7 @@ async def test_create_or_update(self, resource_group): "type": "str", "version": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -81,12 +81,12 @@ async def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_msix_packages_delete(self, resource_group): response = await self.client.msix_packages.delete( resource_group_name=resource_group.name, host_pool_name="str", msix_package_full_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -94,12 +94,12 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_msix_packages_update(self, resource_group): response = await self.client.msix_packages.update( resource_group_name=resource_group.name, host_pool_name="str", msix_package_full_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -107,11 +107,11 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_msix_packages_list(self, resource_group): response = self.client.msix_packages.list( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations.py index 19082f23bd75..dd8a0aab3335 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations.py @@ -20,9 +20,9 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_operations_list(self, resource_group): response = self.client.operations.list( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations_async.py index c1370b13dc27..721c86e579a6 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_operations_async.py @@ -21,9 +21,9 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_operations_list(self, resource_group): response = self.client.operations.list( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations.py index a8bee2db3763..db5bef8ca568 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_workspace(self, resource_group): + def test_private_endpoint_connections_list_by_workspace(self, resource_group): response = self.client.private_endpoint_connections.list_by_workspace( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -32,12 +32,12 @@ def test_list_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get_by_workspace(self, resource_group): + def test_private_endpoint_connections_get_by_workspace(self, resource_group): response = self.client.private_endpoint_connections.get_by_workspace( resource_group_name=resource_group.name, workspace_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -45,12 +45,12 @@ def test_get_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete_by_workspace(self, resource_group): + def test_private_endpoint_connections_delete_by_workspace(self, resource_group): response = self.client.private_endpoint_connections.delete_by_workspace( resource_group_name=resource_group.name, workspace_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -58,7 +58,7 @@ def test_delete_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update_by_workspace(self, resource_group): + def test_private_endpoint_connections_update_by_workspace(self, resource_group): response = self.client.private_endpoint_connections.update_by_workspace( resource_group_name=resource_group.name, workspace_name="str", @@ -80,7 +80,7 @@ def test_update_by_workspace(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -88,11 +88,11 @@ def test_update_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_host_pool(self, resource_group): + def test_private_endpoint_connections_list_by_host_pool(self, resource_group): response = self.client.private_endpoint_connections.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -100,12 +100,12 @@ def test_list_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get_by_host_pool(self, resource_group): + def test_private_endpoint_connections_get_by_host_pool(self, resource_group): response = self.client.private_endpoint_connections.get_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -113,12 +113,12 @@ def test_get_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete_by_host_pool(self, resource_group): + def test_private_endpoint_connections_delete_by_host_pool(self, resource_group): response = self.client.private_endpoint_connections.delete_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -126,7 +126,7 @@ def test_delete_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update_by_host_pool(self, resource_group): + def test_private_endpoint_connections_update_by_host_pool(self, resource_group): response = self.client.private_endpoint_connections.update_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", @@ -148,7 +148,7 @@ def test_update_by_host_pool(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations_async.py index e871e0546acb..6825f8e080e7 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_endpoint_connections_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_workspace(self, resource_group): + async def test_private_endpoint_connections_list_by_workspace(self, resource_group): response = self.client.private_endpoint_connections.list_by_workspace( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -33,12 +33,12 @@ async def test_list_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get_by_workspace(self, resource_group): + async def test_private_endpoint_connections_get_by_workspace(self, resource_group): response = await self.client.private_endpoint_connections.get_by_workspace( resource_group_name=resource_group.name, workspace_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -46,12 +46,12 @@ async def test_get_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete_by_workspace(self, resource_group): + async def test_private_endpoint_connections_delete_by_workspace(self, resource_group): response = await self.client.private_endpoint_connections.delete_by_workspace( resource_group_name=resource_group.name, workspace_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -59,7 +59,7 @@ async def test_delete_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update_by_workspace(self, resource_group): + async def test_private_endpoint_connections_update_by_workspace(self, resource_group): response = await self.client.private_endpoint_connections.update_by_workspace( resource_group_name=resource_group.name, workspace_name="str", @@ -81,7 +81,7 @@ async def test_update_by_workspace(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -89,11 +89,11 @@ async def test_update_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_host_pool(self, resource_group): + async def test_private_endpoint_connections_list_by_host_pool(self, resource_group): response = self.client.private_endpoint_connections.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -101,12 +101,12 @@ async def test_list_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get_by_host_pool(self, resource_group): + async def test_private_endpoint_connections_get_by_host_pool(self, resource_group): response = await self.client.private_endpoint_connections.get_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -114,12 +114,12 @@ async def test_get_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete_by_host_pool(self, resource_group): + async def test_private_endpoint_connections_delete_by_host_pool(self, resource_group): response = await self.client.private_endpoint_connections.delete_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", private_endpoint_connection_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -127,7 +127,7 @@ async def test_delete_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update_by_host_pool(self, resource_group): + async def test_private_endpoint_connections_update_by_host_pool(self, resource_group): response = await self.client.private_endpoint_connections.update_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", @@ -149,7 +149,7 @@ async def test_update_by_host_pool(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations.py index 5048e8fd8bf0..2ebd4a9c42a0 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_workspace(self, resource_group): + def test_private_link_resources_list_by_workspace(self, resource_group): response = self.client.private_link_resources.list_by_workspace( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -32,11 +32,11 @@ def test_list_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_host_pool(self, resource_group): + def test_private_link_resources_list_by_host_pool(self, resource_group): response = self.client.private_link_resources.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations_async.py index c7abaa0bb8f6..402ed378accb 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_private_link_resources_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_workspace(self, resource_group): + async def test_private_link_resources_list_by_workspace(self, resource_group): response = self.client.private_link_resources.list_by_workspace( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -33,11 +33,11 @@ async def test_list_by_workspace(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_host_pool(self, resource_group): + async def test_private_link_resources_list_by_host_pool(self, resource_group): response = self.client.private_link_resources.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations.py index d4536d8b1c08..6138b66fc921 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_scaling_plan_personal_schedules_get(self, resource_group): response = self.client.scaling_plan_personal_schedules.get( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create(self, resource_group): + def test_scaling_plan_personal_schedules_create(self, resource_group): response = self.client.scaling_plan_personal_schedules.create( resource_group_name=resource_group.name, scaling_plan_name="str", @@ -77,7 +77,7 @@ def test_create(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -85,12 +85,12 @@ def test_create(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_scaling_plan_personal_schedules_delete(self, resource_group): response = self.client.scaling_plan_personal_schedules.delete( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -98,12 +98,12 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_scaling_plan_personal_schedules_update(self, resource_group): response = self.client.scaling_plan_personal_schedules.update( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -111,11 +111,11 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_scaling_plan_personal_schedules_list(self, resource_group): response = self.client.scaling_plan_personal_schedules.list( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations_async.py index cb66793c9144..526bd34cb6ce 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_personal_schedules_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_scaling_plan_personal_schedules_get(self, resource_group): response = await self.client.scaling_plan_personal_schedules.get( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -34,7 +34,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create(self, resource_group): + async def test_scaling_plan_personal_schedules_create(self, resource_group): response = await self.client.scaling_plan_personal_schedules.create( resource_group_name=resource_group.name, scaling_plan_name="str", @@ -78,7 +78,7 @@ async def test_create(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -86,12 +86,12 @@ async def test_create(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_scaling_plan_personal_schedules_delete(self, resource_group): response = await self.client.scaling_plan_personal_schedules.delete( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -99,12 +99,12 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_scaling_plan_personal_schedules_update(self, resource_group): response = await self.client.scaling_plan_personal_schedules.update( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -112,11 +112,11 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_scaling_plan_personal_schedules_list(self, resource_group): response = self.client.scaling_plan_personal_schedules.list( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations.py index 973ae0f894fa..c2a8c4e5f500 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_scaling_plan_pooled_schedules_get(self, resource_group): response = self.client.scaling_plan_pooled_schedules.get( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create(self, resource_group): + def test_scaling_plan_pooled_schedules_create(self, resource_group): response = self.client.scaling_plan_pooled_schedules.create( resource_group_name=resource_group.name, scaling_plan_name="str", @@ -68,7 +68,7 @@ def test_create(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -76,12 +76,12 @@ def test_create(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_scaling_plan_pooled_schedules_delete(self, resource_group): response = self.client.scaling_plan_pooled_schedules.delete( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -89,12 +89,12 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_scaling_plan_pooled_schedules_update(self, resource_group): response = self.client.scaling_plan_pooled_schedules.update( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -102,11 +102,11 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_scaling_plan_pooled_schedules_list(self, resource_group): response = self.client.scaling_plan_pooled_schedules.list( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations_async.py index 9ff2d9868812..41f2fdae7971 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plan_pooled_schedules_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_scaling_plan_pooled_schedules_get(self, resource_group): response = await self.client.scaling_plan_pooled_schedules.get( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -34,7 +34,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create(self, resource_group): + async def test_scaling_plan_pooled_schedules_create(self, resource_group): response = await self.client.scaling_plan_pooled_schedules.create( resource_group_name=resource_group.name, scaling_plan_name="str", @@ -69,7 +69,7 @@ async def test_create(self, resource_group): }, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -77,12 +77,12 @@ async def test_create(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_scaling_plan_pooled_schedules_delete(self, resource_group): response = await self.client.scaling_plan_pooled_schedules.delete( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -90,12 +90,12 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_scaling_plan_pooled_schedules_update(self, resource_group): response = await self.client.scaling_plan_pooled_schedules.update( resource_group_name=resource_group.name, scaling_plan_name="str", scaling_plan_schedule_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -103,11 +103,11 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_scaling_plan_pooled_schedules_list(self, resource_group): response = self.client.scaling_plan_pooled_schedules.list( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations.py index cee2eaae558d..954d9dfd1744 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_scaling_plans_get(self, resource_group): response = self.client.scaling_plans.get( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -32,7 +32,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create(self, resource_group): + def test_scaling_plans_create(self, resource_group): response = self.client.scaling_plans.create( resource_group_name=resource_group.name, scaling_plan_name="str", @@ -86,7 +86,7 @@ def test_create(self, resource_group): "tags": {"str": "str"}, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -94,11 +94,11 @@ def test_create(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_scaling_plans_delete(self, resource_group): response = self.client.scaling_plans.delete( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -106,11 +106,11 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_scaling_plans_update(self, resource_group): response = self.client.scaling_plans.update( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -118,10 +118,10 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_resource_group(self, resource_group): + def test_scaling_plans_list_by_resource_group(self, resource_group): response = self.client.scaling_plans.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -129,9 +129,9 @@ def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_subscription(self, resource_group): + def test_scaling_plans_list_by_subscription(self, resource_group): response = self.client.scaling_plans.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -139,11 +139,11 @@ def test_list_by_subscription(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_host_pool(self, resource_group): + def test_scaling_plans_list_by_host_pool(self, resource_group): response = self.client.scaling_plans.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations_async.py index bb5c7899e80d..69e1c4024f96 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_scaling_plans_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_scaling_plans_get(self, resource_group): response = await self.client.scaling_plans.get( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create(self, resource_group): + async def test_scaling_plans_create(self, resource_group): response = await self.client.scaling_plans.create( resource_group_name=resource_group.name, scaling_plan_name="str", @@ -87,7 +87,7 @@ async def test_create(self, resource_group): "tags": {"str": "str"}, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -95,11 +95,11 @@ async def test_create(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_scaling_plans_delete(self, resource_group): response = await self.client.scaling_plans.delete( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -107,11 +107,11 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_scaling_plans_update(self, resource_group): response = await self.client.scaling_plans.update( resource_group_name=resource_group.name, scaling_plan_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -119,10 +119,10 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_resource_group(self, resource_group): + async def test_scaling_plans_list_by_resource_group(self, resource_group): response = self.client.scaling_plans.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -130,9 +130,9 @@ async def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_subscription(self, resource_group): + async def test_scaling_plans_list_by_subscription(self, resource_group): response = self.client.scaling_plans.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -140,11 +140,11 @@ async def test_list_by_subscription(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_host_pool(self, resource_group): + async def test_scaling_plans_list_by_host_pool(self, resource_group): response = self.client.scaling_plans.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations.py index f6da35d6d8da..687069577f1e 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations.py @@ -20,12 +20,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_session_hosts_get(self, resource_group): response = self.client.session_hosts.get( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,12 +33,12 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_session_hosts_delete(self, resource_group): response = self.client.session_hosts.delete( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -46,12 +46,12 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_session_hosts_update(self, resource_group): response = self.client.session_hosts.update( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -59,11 +59,11 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_session_hosts_list(self, resource_group): response = self.client.session_hosts.list( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations_async.py index 3760951a7af3..9ce5a9532ff9 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_session_hosts_operations_async.py @@ -21,12 +21,12 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_session_hosts_get(self, resource_group): response = await self.client.session_hosts.get( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -34,12 +34,12 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_session_hosts_delete(self, resource_group): response = await self.client.session_hosts.delete( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -47,12 +47,12 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_session_hosts_update(self, resource_group): response = await self.client.session_hosts.update( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -60,11 +60,11 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_session_hosts_list(self, resource_group): response = self.client.session_hosts.list( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations.py index 0f2cf1687abc..9afad4e52b9b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_start_menu_items_list(self, resource_group): response = self.client.start_menu_items.list( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations_async.py index 0cc0958c5005..42f874d75a31 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_start_menu_items_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_start_menu_items_list(self, resource_group): response = self.client.start_menu_items.list( resource_group_name=resource_group.name, application_group_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations.py index 8b9a2c864beb..53169f59f6d2 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_host_pool(self, resource_group): + def test_user_sessions_list_by_host_pool(self, resource_group): response = self.client.user_sessions.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -32,13 +32,13 @@ def test_list_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_user_sessions_get(self, resource_group): response = self.client.user_sessions.get( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -46,13 +46,13 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_user_sessions_delete(self, resource_group): response = self.client.user_sessions.delete( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -60,12 +60,12 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list(self, resource_group): + def test_user_sessions_list(self, resource_group): response = self.client.user_sessions.list( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -73,13 +73,13 @@ def test_list(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_disconnect(self, resource_group): + def test_user_sessions_disconnect(self, resource_group): response = self.client.user_sessions.disconnect( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -87,13 +87,13 @@ def test_disconnect(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_send_message(self, resource_group): + def test_user_sessions_send_message(self, resource_group): response = self.client.user_sessions.send_message( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations_async.py index a03d5750b173..84c6073de9a1 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_user_sessions_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_host_pool(self, resource_group): + async def test_user_sessions_list_by_host_pool(self, resource_group): response = self.client.user_sessions.list_by_host_pool( resource_group_name=resource_group.name, host_pool_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -33,13 +33,13 @@ async def test_list_by_host_pool(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_user_sessions_get(self, resource_group): response = await self.client.user_sessions.get( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -47,13 +47,13 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_user_sessions_delete(self, resource_group): response = await self.client.user_sessions.delete( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -61,12 +61,12 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list(self, resource_group): + async def test_user_sessions_list(self, resource_group): response = self.client.user_sessions.list( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -74,13 +74,13 @@ async def test_list(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_disconnect(self, resource_group): + async def test_user_sessions_disconnect(self, resource_group): response = await self.client.user_sessions.disconnect( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -88,13 +88,13 @@ async def test_disconnect(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_send_message(self, resource_group): + async def test_user_sessions_send_message(self, resource_group): response = await self.client.user_sessions.send_message( resource_group_name=resource_group.name, host_pool_name="str", session_host_name="str", user_session_id="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations.py index aee123acbae0..24d155634fa1 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations.py @@ -20,11 +20,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_get(self, resource_group): + def test_workspaces_get(self, resource_group): response = self.client.workspaces.get( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -32,7 +32,7 @@ def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_create_or_update(self, resource_group): + def test_workspaces_create_or_update(self, resource_group): response = self.client.workspaces.create_or_update( resource_group_name=resource_group.name, workspace_name="str", @@ -86,7 +86,7 @@ def test_create_or_update(self, resource_group): "tags": {"str": "str"}, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -94,11 +94,11 @@ def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_delete(self, resource_group): + def test_workspaces_delete(self, resource_group): response = self.client.workspaces.delete( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -106,11 +106,11 @@ def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_update(self, resource_group): + def test_workspaces_update(self, resource_group): response = self.client.workspaces.update( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -118,10 +118,10 @@ def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_resource_group(self, resource_group): + def test_workspaces_list_by_resource_group(self, resource_group): response = self.client.workspaces.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself @@ -129,9 +129,9 @@ def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy - def test_list_by_subscription(self, resource_group): + def test_workspaces_list_by_subscription(self, resource_group): response = self.client.workspaces.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r for r in response] # please add some check logic here by yourself diff --git a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations_async.py b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations_async.py index dd1d71f33f85..b3b8eecdc44b 100644 --- a/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations_async.py +++ b/sdk/desktopvirtualization/azure-mgmt-desktopvirtualization/generated_tests/test_desktop_virtualization_mgmt_workspaces_operations_async.py @@ -21,11 +21,11 @@ def setup_method(self, method): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_get(self, resource_group): + async def test_workspaces_get(self, resource_group): response = await self.client.workspaces.get( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -33,7 +33,7 @@ async def test_get(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_create_or_update(self, resource_group): + async def test_workspaces_create_or_update(self, resource_group): response = await self.client.workspaces.create_or_update( resource_group_name=resource_group.name, workspace_name="str", @@ -87,7 +87,7 @@ async def test_create_or_update(self, resource_group): "tags": {"str": "str"}, "type": "str", }, - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -95,11 +95,11 @@ async def test_create_or_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_delete(self, resource_group): + async def test_workspaces_delete(self, resource_group): response = await self.client.workspaces.delete( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -107,11 +107,11 @@ async def test_delete(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_update(self, resource_group): + async def test_workspaces_update(self, resource_group): response = await self.client.workspaces.update( resource_group_name=resource_group.name, workspace_name="str", - api_version="2024-04-03", + api_version="2024-09-10", ) # please add some check logic here by yourself @@ -119,10 +119,10 @@ async def test_update(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_resource_group(self, resource_group): + async def test_workspaces_list_by_resource_group(self, resource_group): response = self.client.workspaces.list_by_resource_group( resource_group_name=resource_group.name, - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself @@ -130,9 +130,9 @@ async def test_list_by_resource_group(self, resource_group): @RandomNameResourceGroupPreparer(location=AZURE_LOCATION) @recorded_by_proxy_async - async def test_list_by_subscription(self, resource_group): + async def test_workspaces_list_by_subscription(self, resource_group): response = self.client.workspaces.list_by_subscription( - api_version="2024-04-03", + api_version="2024-09-10", ) result = [r async for r in response] # please add some check logic here by yourself