Skip to content

Commit

Permalink
CodeGen from PR 21262 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 07b0ceff8f5afa426e0715166cdc61a9f798a387 into dcec109c164e69f0f122ff74fc551108da8af20e
  • Loading branch information
SDKAuto committed Oct 26, 2022
1 parent e5db378 commit 6cdce3a
Show file tree
Hide file tree
Showing 1,271 changed files with 18,914 additions and 46,652 deletions.
8 changes: 4 additions & 4 deletions sdk/compute/azure-mgmt-compute/_meta.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"commit": "ee41e311448ea07d35e7e5df0fbe0cfe897eda70",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest": "3.9.2",
"use": [
"@autorest/python@6.1.11",
"@autorest/python@6.2.1",
"@autorest/[email protected]"
],
"commit": "3cc85e694a07ba8ea5d0f21cefef71205dc3846e",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest_command": "autorest specification/compute/resource-manager/readme.md --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --use=@autorest/[email protected] --use=@autorest/[email protected] --version=3.9.2 --version-tolerant=False",
"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] --use=@autorest/[email protected] --version=3.9.2 --version-tolerant=False",
"readme": "specification/compute/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@
_patch_all = []
from ._patch import patch_sdk as _patch_sdk

__all__ = ["ComputeManagementClient"]
__all__ = [
"ComputeManagementClient",
]
__all__.extend([p for p in _patch_all if p not in __all__])

_patch_sdk()
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

import sys
from typing import Any, TYPE_CHECKING

from azure.core.configuration import Configuration
Expand All @@ -14,6 +15,11 @@

from ._version import VERSION

if sys.version_info >= (3, 8):
from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports
else:
from typing_extensions import Literal # type: ignore # pylint: disable=ungrouped-imports

if TYPE_CHECKING:
# pylint: disable=unused-import,ungrouped-imports
from azure.core.credentials import TokenCredential
Expand All @@ -37,7 +43,7 @@ class ComputeManagementClientConfiguration(Configuration): # pylint: disable=to

def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None:
super(ComputeManagementClientConfiguration, self).__init__(**kwargs)
api_version = kwargs.pop("api_version", "2015-06-15") # type: str
api_version = kwargs.pop("api_version", "2015-06-15") # type: Literal["2015-06-15"]

if credential is None:
raise ValueError("Parameter 'credential' must not be None.")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,4 +107,4 @@
"virtual_machine_scale_sets": "VirtualMachineScaleSetsOperations",
"virtual_machine_scale_set_vms": "VirtualMachineScaleSetVMsOperations"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

VERSION = "29.0.0"
VERSION = "1.0.0b1"
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
_patch_all = []
from ._patch import patch_sdk as _patch_sdk

__all__ = ["ComputeManagementClient"]
__all__ = [
"ComputeManagementClient",
]
__all__.extend([p for p in _patch_all if p not in __all__])

_patch_sdk()
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

import sys
from typing import Any, TYPE_CHECKING

from azure.core.configuration import Configuration
Expand All @@ -14,6 +15,11 @@

from .._version import VERSION

if sys.version_info >= (3, 8):
from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports
else:
from typing_extensions import Literal # type: ignore # pylint: disable=ungrouped-imports

if TYPE_CHECKING:
# pylint: disable=unused-import,ungrouped-imports
from azure.core.credentials_async import AsyncTokenCredential
Expand All @@ -37,7 +43,7 @@ class ComputeManagementClientConfiguration(Configuration): # pylint: disable=to

def __init__(self, credential: "AsyncTokenCredential", subscription_id: str, **kwargs: Any) -> None:
super(ComputeManagementClientConfiguration, self).__init__(**kwargs)
api_version = kwargs.pop("api_version", "2015-06-15") # type: str
api_version = kwargs.pop("api_version", "2015-06-15") # type: Literal["2015-06-15"]

if credential is None:
raise ValueError("Parameter 'credential' must not be None.")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------
import sys
from typing import Any, AsyncIterable, Callable, Dict, IO, Optional, TypeVar, Union, overload
import urllib.parse

Expand Down Expand Up @@ -36,6 +37,10 @@
build_list_request,
)

if sys.version_info >= (3, 8):
from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports
else:
from typing_extensions import Literal # type: ignore # pylint: disable=ungrouped-imports
T = TypeVar("T")
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]

Expand Down Expand Up @@ -145,7 +150,7 @@ async def create_or_update(
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
content_type = kwargs.pop("content_type", _headers.pop("Content-Type", None)) # type: Optional[str]
cls = kwargs.pop("cls", None) # type: ClsType[_models.AvailabilitySet]

Expand Down Expand Up @@ -217,7 +222,7 @@ async def delete(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[Optional[_models.OperationStatusResponse]]

request = build_delete_request(
Expand Down Expand Up @@ -277,7 +282,7 @@ async def get(self, resource_group_name: str, availability_set_name: str, **kwar
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[_models.AvailabilitySet]

request = build_get_request(
Expand Down Expand Up @@ -326,7 +331,7 @@ def list(self, resource_group_name: str, **kwargs: Any) -> AsyncIterable["_model
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[_models.AvailabilitySetListResult]

error_map = {
Expand Down Expand Up @@ -414,7 +419,7 @@ def list_available_sizes(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[_models.VirtualMachineSizeListResult]

error_map = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------
import sys
from typing import Any, AsyncIterable, Callable, Dict, Optional, TypeVar
import urllib.parse

Expand All @@ -29,6 +30,10 @@
from ..._vendor import _convert_request
from ...operations._usage_operations import build_list_request

if sys.version_info >= (3, 8):
from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports
else:
from typing_extensions import Literal # type: ignore # pylint: disable=ungrouped-imports
T = TypeVar("T")
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]

Expand Down Expand Up @@ -67,7 +72,7 @@ def list(self, location: str, **kwargs: Any) -> AsyncIterable["_models.Usage"]:
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[_models.ListUsagesResult]

error_map = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------
import sys
from typing import Any, Callable, Dict, List, Optional, TypeVar

from azure.core.exceptions import (
Expand All @@ -31,6 +32,10 @@
build_list_versions_request,
)

if sys.version_info >= (3, 8):
from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports
else:
from typing_extensions import Literal # type: ignore # pylint: disable=ungrouped-imports
T = TypeVar("T")
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]

Expand Down Expand Up @@ -84,7 +89,7 @@ async def get(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[_models.VirtualMachineExtensionImage]

request = build_get_request(
Expand Down Expand Up @@ -146,7 +151,7 @@ async def list_types(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[List[_models.VirtualMachineExtensionImage]]

request = build_list_types_request(
Expand Down Expand Up @@ -221,7 +226,7 @@ async def list_versions(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[List[_models.VirtualMachineExtensionImage]]

request = build_list_versions_request(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------
import sys
from typing import Any, Callable, Dict, IO, Optional, TypeVar, Union, cast, overload

from azure.core.exceptions import (
Expand Down Expand Up @@ -34,6 +35,10 @@
build_update_request,
)

if sys.version_info >= (3, 8):
from typing import Literal # pylint: disable=no-name-in-module, ungrouped-imports
else:
from typing_extensions import Literal # type: ignore # pylint: disable=ungrouped-imports
T = TypeVar("T")
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]

Expand Down Expand Up @@ -76,7 +81,7 @@ async def _create_or_update_initial(
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
content_type = kwargs.pop("content_type", _headers.pop("Content-Type", None)) # type: Optional[str]
cls = kwargs.pop("cls", None) # type: ClsType[_models.VirtualMachineExtension]

Expand Down Expand Up @@ -251,7 +256,7 @@ async def begin_create_or_update(
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
content_type = kwargs.pop("content_type", _headers.pop("Content-Type", None)) # type: Optional[str]
cls = kwargs.pop("cls", None) # type: ClsType[_models.VirtualMachineExtension]
polling = kwargs.pop("polling", True) # type: Union[bool, AsyncPollingMethod]
Expand Down Expand Up @@ -314,7 +319,7 @@ async def _update_initial(
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
content_type = kwargs.pop("content_type", _headers.pop("Content-Type", None)) # type: Optional[str]
cls = kwargs.pop("cls", None) # type: ClsType[_models.VirtualMachineExtension]

Expand Down Expand Up @@ -486,7 +491,7 @@ async def begin_update(
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
content_type = kwargs.pop("content_type", _headers.pop("Content-Type", None)) # type: Optional[str]
cls = kwargs.pop("cls", None) # type: ClsType[_models.VirtualMachineExtension]
polling = kwargs.pop("polling", True) # type: Union[bool, AsyncPollingMethod]
Expand Down Expand Up @@ -544,7 +549,7 @@ async def _delete_initial(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[Optional[_models.OperationStatusResponse]]

request = build_delete_request(
Expand Down Expand Up @@ -611,7 +616,7 @@ async def begin_delete(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[_models.OperationStatusResponse]
polling = kwargs.pop("polling", True) # type: Union[bool, AsyncPollingMethod]
lro_delay = kwargs.pop("polling_interval", self._config.polling_interval)
Expand Down Expand Up @@ -687,7 +692,7 @@ async def get(
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: str
api_version = kwargs.pop("api_version", _params.pop("api-version", "2015-06-15")) # type: Literal["2015-06-15"]
cls = kwargs.pop("cls", None) # type: ClsType[_models.VirtualMachineExtension]

request = build_get_request(
Expand Down
Loading

0 comments on commit 6cdce3a

Please sign in to comment.