Skip to content

Commit 9b41840

Browse files
author
SDKAuto
committed
CodeGen from PR 23823 in Azure/azure-rest-api-specs
Merge bc46f18786439d719514e4db1ee7ac6a3faee361 into 104416d2165e106d35e41a45583129765a6cc5ba
1 parent ec855c2 commit 9b41840

File tree

2,184 files changed

+1359332
-94369
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,184 files changed

+1359332
-94369
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"commit": "06042d4ffed6a1ea8319c39cd07ea21efe5d49f7",
2+
"commit": "af3175502668b1301136d81214c04ad1476bf4b9",
33
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
44
"autorest": "3.9.2",
55
"use": [
6-
"@autorest/[email protected].7",
6+
"@autorest/[email protected].12",
77
"@autorest/[email protected]"
88
],
9-
"autorest_command": "autorest specification/compute/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --use=@autorest/[email protected].7 --use=@autorest/[email protected] --version=3.9.2 --version-tolerant=False",
9+
"autorest_command": "autorest specification/compute/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-python/sdk --use=@autorest/[email protected].12 --use=@autorest/[email protected] --version=3.9.2 --version-tolerant=False",
1010
"readme": "specification/compute/resource-manager/readme.md"
1111
}

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/__init__.py

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,21 +6,15 @@
66
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
77
# --------------------------------------------------------------------------
88

9-
from ._client import ComputeManagementClient
10-
from ._version import VERSION
11-
12-
__version__ = VERSION
9+
from ._compute_management_client import ComputeManagementClient
10+
__all__ = ['ComputeManagementClient']
1311

1412
try:
15-
from ._patch import __all__ as _patch_all
16-
from ._patch import * # pylint: disable=unused-wildcard-import
13+
from ._patch import patch_sdk # type: ignore
14+
patch_sdk()
1715
except ImportError:
18-
_patch_all = []
19-
from ._patch import patch_sdk as _patch_sdk
16+
pass
2017

21-
__all__ = [
22-
"ComputeManagementClient",
23-
]
24-
__all__.extend([p for p in _patch_all if p not in __all__])
18+
from ._version import VERSION
2519

26-
_patch_sdk()
20+
__version__ = VERSION

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/_client.py

Lines changed: 0 additions & 857 deletions
This file was deleted.

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/_compute_management_client.py

Lines changed: 2419 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
33
# Copyright (c) Microsoft Corporation. All rights reserved.
4-
# Licensed under the MIT License. See License.txt in the project root for license information.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
57
# Code generated by Microsoft (R) AutoRest Code Generator.
6-
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
710
# --------------------------------------------------------------------------
8-
911
from typing import Any, TYPE_CHECKING
1012

1113
from azure.core.configuration import Configuration
@@ -18,50 +20,48 @@
1820
# pylint: disable=unused-import,ungrouped-imports
1921
from azure.core.credentials import TokenCredential
2022

21-
22-
class ComputeManagementClientConfiguration(Configuration): # pylint: disable=too-many-instance-attributes
23+
class ComputeManagementClientConfiguration(Configuration):
2324
"""Configuration for ComputeManagementClient.
2425
2526
Note that all parameters used to create this instance are saved as instance
2627
attributes.
2728
2829
:param credential: Credential needed for the client to connect to Azure. Required.
2930
:type credential: ~azure.core.credentials.TokenCredential
30-
:param subscription_id: Subscription credentials which uniquely identify Microsoft Azure
31-
subscription. The subscription ID forms part of the URI for every service call. Required.
31+
:param subscription_id: Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. Required.
3232
:type subscription_id: str
33-
:keyword api_version: Api Version. Default value is "2022-11-01". Note that overriding this
34-
default value may result in unsupported behavior.
35-
:paramtype api_version: str
3633
"""
3734

38-
def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None:
39-
super(ComputeManagementClientConfiguration, self).__init__(**kwargs)
40-
api_version: str = kwargs.pop("api_version", "2022-11-01")
41-
35+
def __init__(
36+
self,
37+
credential: "TokenCredential",
38+
subscription_id: str,
39+
**kwargs: Any
40+
):
4241
if credential is None:
4342
raise ValueError("Parameter 'credential' must not be None.")
4443
if subscription_id is None:
4544
raise ValueError("Parameter 'subscription_id' must not be None.")
45+
super(ComputeManagementClientConfiguration, self).__init__(**kwargs)
4646

4747
self.credential = credential
4848
self.subscription_id = subscription_id
49-
self.api_version = api_version
50-
self.credential_scopes = kwargs.pop("credential_scopes", ["https://management.azure.com/.default"])
51-
kwargs.setdefault("sdk_moniker", "mgmt-compute/{}".format(VERSION))
49+
self.credential_scopes = kwargs.pop('credential_scopes', ['https://management.azure.com/.default'])
50+
kwargs.setdefault('sdk_moniker', 'azure-mgmt-compute/{}'.format(VERSION))
5251
self._configure(**kwargs)
5352

54-
def _configure(self, **kwargs: Any) -> None:
55-
self.user_agent_policy = kwargs.get("user_agent_policy") or policies.UserAgentPolicy(**kwargs)
56-
self.headers_policy = kwargs.get("headers_policy") or policies.HeadersPolicy(**kwargs)
57-
self.proxy_policy = kwargs.get("proxy_policy") or policies.ProxyPolicy(**kwargs)
58-
self.logging_policy = kwargs.get("logging_policy") or policies.NetworkTraceLoggingPolicy(**kwargs)
59-
self.http_logging_policy = kwargs.get("http_logging_policy") or ARMHttpLoggingPolicy(**kwargs)
60-
self.retry_policy = kwargs.get("retry_policy") or policies.RetryPolicy(**kwargs)
61-
self.custom_hook_policy = kwargs.get("custom_hook_policy") or policies.CustomHookPolicy(**kwargs)
62-
self.redirect_policy = kwargs.get("redirect_policy") or policies.RedirectPolicy(**kwargs)
63-
self.authentication_policy = kwargs.get("authentication_policy")
53+
def _configure(
54+
self,
55+
**kwargs: Any
56+
):
57+
self.user_agent_policy = kwargs.get('user_agent_policy') or policies.UserAgentPolicy(**kwargs)
58+
self.headers_policy = kwargs.get('headers_policy') or policies.HeadersPolicy(**kwargs)
59+
self.proxy_policy = kwargs.get('proxy_policy') or policies.ProxyPolicy(**kwargs)
60+
self.logging_policy = kwargs.get('logging_policy') or policies.NetworkTraceLoggingPolicy(**kwargs)
61+
self.http_logging_policy = kwargs.get('http_logging_policy') or ARMHttpLoggingPolicy(**kwargs)
62+
self.retry_policy = kwargs.get('retry_policy') or policies.RetryPolicy(**kwargs)
63+
self.custom_hook_policy = kwargs.get('custom_hook_policy') or policies.CustomHookPolicy(**kwargs)
64+
self.redirect_policy = kwargs.get('redirect_policy') or policies.RedirectPolicy(**kwargs)
65+
self.authentication_policy = kwargs.get('authentication_policy')
6466
if self.credential and not self.authentication_policy:
65-
self.authentication_policy = ARMChallengeAuthenticationPolicy(
66-
self.credential, *self.credential_scopes, **kwargs
67-
)
67+
self.authentication_policy = ARMChallengeAuthenticationPolicy(self.credential, *self.credential_scopes, **kwargs)

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/_validation.py

Lines changed: 0 additions & 53 deletions
This file was deleted.
Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
# coding=utf-8
22
# --------------------------------------------------------------------------
33
# Copyright (c) Microsoft Corporation. All rights reserved.
4-
# Licensed under the MIT License. See License.txt in the project root for license information.
5-
# Code generated by Microsoft (R) AutoRest Code Generator.
6-
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
76
# --------------------------------------------------------------------------
87

9-
VERSION = "29.2.0b2"
8+
VERSION = "0.1.0"

sdk/compute/azure-mgmt-compute/azure/mgmt/compute/aio/__init__.py

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,5 @@
66
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
77
# --------------------------------------------------------------------------
88

9-
from ._client import ComputeManagementClient
10-
11-
try:
12-
from ._patch import __all__ as _patch_all
13-
from ._patch import * # pylint: disable=unused-wildcard-import
14-
except ImportError:
15-
_patch_all = []
16-
from ._patch import patch_sdk as _patch_sdk
17-
18-
__all__ = [
19-
"ComputeManagementClient",
20-
]
21-
__all__.extend([p for p in _patch_all if p not in __all__])
22-
23-
_patch_sdk()
9+
from ._compute_management_client import ComputeManagementClient
10+
__all__ = ['ComputeManagementClient']

0 commit comments

Comments
 (0)