Skip to content

Commit

Permalink
[AutoRelease] t2-monitor-2023-05-04-08934(can only be merged by SDK o…
Browse files Browse the repository at this point in the history
…wner) (Azure#30223)

* code and test

* update

---------

Co-authored-by: PythonSdkPipelines <PythonSdkPipelines>
Co-authored-by: msyyc <70930885+msyyc@users.noreply.github.com>
  • Loading branch information
azure-sdk and msyyc authored May 4, 2023
1 parent 493dc78 commit 17f950a
Show file tree
Hide file tree
Showing 378 changed files with 5,362 additions and 7,440 deletions.
6 changes: 6 additions & 0 deletions sdk/monitor/azure-mgmt-monitor/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release History

## 6.0.1 (2023-05-04)

### Other Changes

- Fixed annotation about namespace

## 6.0.0 (2023-03-20)

### Features Added
Expand Down
5 changes: 3 additions & 2 deletions sdk/monitor/azure-mgmt-monitor/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,9 @@ client = MonitorManagementClient(credential=DefaultAzureCredential(), subscripti

## Examples


Code samples for this package can be found at [Monitor](https://docs.microsoft.com/samples/browse/?languages=python&term=Getting%20started%20-%20Managing&terms=Getting%20started%20-%20Managing) on docs.microsoft.com and [Samples Repo](https://aka.ms/azsdk/python/mgmt/samples)
Code samples for this package can be found at:
- [Search Monitor](https://docs.microsoft.com/samples/browse/?languages=python&term=Getting%20started%20-%20Managing&terms=Getting%20started%20-%20Managing) on docs.microsoft.com
- [Azure Python Mgmt SDK Samples Repo](https://aka.ms/azsdk/python/mgmt/samples)


## Troubleshooting
Expand Down
6 changes: 3 additions & 3 deletions sdk/monitor/azure-mgmt-monitor/_meta.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"commit": "7d313ecb6a58a51046a3916ee5ea6b6d29973522",
"commit": "817e7cea0b7e3194868825cbef6d4e62a7895951",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest": "3.9.2",
"use": [
"@autorest/python@6.4.3",
"@autorest/python@6.4.8",
"@autorest/modelerfour@4.24.3"
],
"autorest_command": "autorest specification/monitor/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/python@6.4.3 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False",
"autorest_command": "autorest specification/monitor/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/python@6.4.8 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False",
"readme": "specification/monitor/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -631,7 +631,7 @@ def _serialize(self, target_obj, data_type=None, **kwargs):
if xml_desc.get("attr", False):
if xml_ns:
ET.register_namespace(xml_prefix, xml_ns)
xml_name = "{}{}".format(xml_ns, xml_name)
xml_name = "{{{}}}{}".format(xml_ns, xml_name)
serialized.set(xml_name, new_attr) # type: ignore
continue
if xml_desc.get("text", False):
Expand Down Expand Up @@ -1273,7 +1273,7 @@ def _extract_name_from_internal_type(internal_type):
xml_name = internal_type_xml_map.get("name", internal_type.__name__)
xml_ns = internal_type_xml_map.get("ns", None)
if xml_ns:
xml_name = "{}{}".format(xml_ns, xml_name)
xml_name = "{{{}}}{}".format(xml_ns, xml_name)
return xml_name


Expand All @@ -1297,7 +1297,7 @@ def xml_key_extractor(attr, attr_desc, data):
# Integrate namespace if necessary
xml_ns = xml_desc.get("ns", internal_type_xml_map.get("ns", None))
if xml_ns:
xml_name = "{}{}".format(xml_ns, xml_name)
xml_name = "{{{}}}{}".format(xml_ns, xml_name)

# If it's an attribute, that's simple
if xml_desc.get("attr", False):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@
# license information.
# --------------------------------------------------------------------------

VERSION = "6.0.0"
VERSION = "6.0.1"
Original file line number Diff line number Diff line change
Expand Up @@ -33,20 +33,19 @@ class MonitorManagementClient: # pylint: disable=client-accepts-api-version-key
"""Monitor Management Client.
:ivar activity_logs: ActivityLogsOperations operations
:vartype activity_logs: $(python-base-namespace).v2015_04_01.operations.ActivityLogsOperations
:vartype activity_logs: azure.mgmt.monitor.v2015_04_01.operations.ActivityLogsOperations
:ivar autoscale_settings: AutoscaleSettingsOperations operations
:vartype autoscale_settings:
$(python-base-namespace).v2015_04_01.operations.AutoscaleSettingsOperations
azure.mgmt.monitor.v2015_04_01.operations.AutoscaleSettingsOperations
:ivar event_categories: EventCategoriesOperations operations
:vartype event_categories:
$(python-base-namespace).v2015_04_01.operations.EventCategoriesOperations
:vartype event_categories: azure.mgmt.monitor.v2015_04_01.operations.EventCategoriesOperations
:ivar operations: Operations operations
:vartype operations: $(python-base-namespace).v2015_04_01.operations.Operations
:vartype operations: azure.mgmt.monitor.v2015_04_01.operations.Operations
:ivar tenant_activity_logs: TenantActivityLogsOperations operations
:vartype tenant_activity_logs:
$(python-base-namespace).v2015_04_01.operations.TenantActivityLogsOperations
azure.mgmt.monitor.v2015_04_01.operations.TenantActivityLogsOperations
:ivar alert_rules: AlertRulesOperations operations
:vartype alert_rules: $(python-base-namespace).v2015_04_01.operations.AlertRulesOperations
:vartype alert_rules: azure.mgmt.monitor.v2015_04_01.operations.AlertRulesOperations
:param credential: Credential needed for the client to connect to Azure. Required.
:type credential: ~azure.core.credentials.TokenCredential
:param subscription_id: The ID of the target subscription. Required.
Expand Down
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 = "6.0.0"
VERSION = "6.0.1"
Original file line number Diff line number Diff line change
Expand Up @@ -33,21 +33,20 @@ class MonitorManagementClient: # pylint: disable=client-accepts-api-version-key
"""Monitor Management Client.
:ivar activity_logs: ActivityLogsOperations operations
:vartype activity_logs:
$(python-base-namespace).v2015_04_01.aio.operations.ActivityLogsOperations
:vartype activity_logs: azure.mgmt.monitor.v2015_04_01.aio.operations.ActivityLogsOperations
:ivar autoscale_settings: AutoscaleSettingsOperations operations
:vartype autoscale_settings:
$(python-base-namespace).v2015_04_01.aio.operations.AutoscaleSettingsOperations
azure.mgmt.monitor.v2015_04_01.aio.operations.AutoscaleSettingsOperations
:ivar event_categories: EventCategoriesOperations operations
:vartype event_categories:
$(python-base-namespace).v2015_04_01.aio.operations.EventCategoriesOperations
azure.mgmt.monitor.v2015_04_01.aio.operations.EventCategoriesOperations
:ivar operations: Operations operations
:vartype operations: $(python-base-namespace).v2015_04_01.aio.operations.Operations
:vartype operations: azure.mgmt.monitor.v2015_04_01.aio.operations.Operations
:ivar tenant_activity_logs: TenantActivityLogsOperations operations
:vartype tenant_activity_logs:
$(python-base-namespace).v2015_04_01.aio.operations.TenantActivityLogsOperations
azure.mgmt.monitor.v2015_04_01.aio.operations.TenantActivityLogsOperations
:ivar alert_rules: AlertRulesOperations operations
:vartype alert_rules: $(python-base-namespace).v2015_04_01.aio.operations.AlertRulesOperations
:vartype alert_rules: azure.mgmt.monitor.v2015_04_01.aio.operations.AlertRulesOperations
:param credential: Credential needed for the client to connect to Azure. Required.
:type credential: ~azure.core.credentials_async.AsyncTokenCredential
:param subscription_id: The ID of the target subscription. Required.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
# 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

from azure.core.async_paging import AsyncItemPaged, AsyncList
Expand All @@ -29,10 +28,6 @@
from ..._vendor import _convert_request
from ...operations._activity_logs_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 All @@ -43,7 +38,7 @@ class ActivityLogsOperations:
**DO NOT** instantiate this class directly.
Instead, you should access the following operations through
:class:`~$(python-base-namespace).v2015_04_01.aio.MonitorManagementClient`'s
:class:`~azure.mgmt.monitor.v2015_04_01.aio.MonitorManagementClient`'s
:attr:`activity_logs` attribute.
"""

Expand Down Expand Up @@ -87,13 +82,13 @@ def list(self, filter: str, select: Optional[str] = None, **kwargs: Any) -> Asyn
:keyword callable cls: A custom type or function that will be passed the direct response
:return: An iterator like instance of either EventData or the result of cls(response)
:rtype:
~azure.core.async_paging.AsyncItemPaged[~$(python-base-namespace).v2015_04_01.models.EventData]
~azure.core.async_paging.AsyncItemPaged[~azure.mgmt.monitor.v2015_04_01.models.EventData]
:raises ~azure.core.exceptions.HttpResponseError:
"""
_headers = kwargs.pop("headers", {}) or {}
_params = case_insensitive_dict(kwargs.pop("params", {}) or {})

api_version: Literal["2015-04-01"] = kwargs.pop("api_version", _params.pop("api-version", "2015-04-01"))
api_version: str = kwargs.pop("api_version", _params.pop("api-version", "2015-04-01"))
cls: ClsType[_models.EventDataCollection] = kwargs.pop("cls", None)

error_map = {
Expand Down
Loading

0 comments on commit 17f950a

Please sign in to comment.