Skip to content

Commit ac1354d

Browse files
azure-sdkChenxiJiang333msyycCopilot
authored
[AutoPR azure-mgmt-planetarycomputer]-generated-from-SDK Generation - Python-6062568 (#45908)
* Configurations: 'specification/orbitalplanetarycomputer/Orbital.Management/tspconfig.yaml', API Version: 2026-04-15, SDK Release Type: stable, and CommitSHA: '5e21babae10dd7056c3005bb51da815f0495f1aa' in SpecRepo: 'https://github.com/Azure/azure-rest-api-specs' Pipeline run: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=6062568 Refer to https://eng.ms/docs/products/azure-developer-experience/develop/sdk-release/sdk-release-prerequisites to prepare for SDK release. * update * Apply suggestion from @Copilot Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: ChenxiJiang333 <v-chenjiang@microsoft.com> Co-authored-by: Yuchao Yan <yuchaoyan@microsoft.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: ChenxiJiang333 <119990644+ChenxiJiang333@users.noreply.github.com>
1 parent 166267c commit ac1354d

34 files changed

Lines changed: 499 additions & 268 deletions

sdk/planetarycomputer/azure-mgmt-planetarycomputer/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Release History
22

3+
## 1.0.0 (2026-03-25)
4+
5+
### Features Added
6+
7+
- Client `PlanetaryComputerMgmtClient` added parameter `cloud_setting` in method `__init__`
8+
39
## 1.0.0b1 (2025-05-20)
410

511
### Other Changes
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
recursive-include tests *.py *.json
2-
recursive-include samples *.py *.md
31
include *.md
4-
include azure/__init__.py
5-
include azure/mgmt/__init__.py
62
include LICENSE
73
include azure/mgmt/planetarycomputer/py.typed
4+
recursive-include tests *.py
5+
recursive-include samples *.py *.md
6+
include azure/__init__.py
7+
include azure/mgmt/__init__.py
Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
{
2-
"commit": "03a6598cdc38924f9eaaeb03f8ef151f5aeff449",
2+
"apiVersion": "2026-04-15",
3+
"apiVersions": {
4+
"Microsoft.Spatio": "2026-04-15"
5+
},
6+
"commit": "5e21babae10dd7056c3005bb51da815f0495f1aa",
37
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
48
"typespec_src": "specification/orbitalplanetarycomputer/Orbital.Management",
5-
"emitterVersion": "0.44.2"
9+
"emitterVersion": "0.61.1"
610
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__path__ = __import__("pkgutil").extend_path(__path__, __name__)
1+
__path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__path__ = __import__("pkgutil").extend_path(__path__, __name__)
1+
__path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore

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

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
from .operations import GeoCatalogsOperations
2323

2424
if TYPE_CHECKING:
25+
from azure.core import AzureClouds
2526
from azure.core.credentials import TokenCredential
2627

2728

@@ -36,19 +37,28 @@ class PlanetaryComputerMgmtClient:
3637
:type subscription_id: str
3738
:param base_url: Service host. Default value is None.
3839
:type base_url: str
39-
:keyword api_version: The API version to use for this operation. Default value is
40-
"2025-02-11-preview". Note that overriding this default value may result in unsupported
41-
behavior.
40+
:keyword cloud_setting: The cloud setting for which to get the ARM endpoint. Default value is
41+
None.
42+
:paramtype cloud_setting: ~azure.core.AzureClouds
43+
:keyword api_version: The API version to use for this operation. Known values are "2026-04-15".
44+
Default value is "2026-04-15". Note that overriding this default value may result in
45+
unsupported behavior.
4246
:paramtype api_version: str
4347
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
4448
Retry-After header is present.
4549
"""
4650

4751
def __init__(
48-
self, credential: "TokenCredential", subscription_id: str, base_url: Optional[str] = None, **kwargs: Any
52+
self,
53+
credential: "TokenCredential",
54+
subscription_id: str,
55+
base_url: Optional[str] = None,
56+
*,
57+
cloud_setting: Optional["AzureClouds"] = None,
58+
**kwargs: Any
4959
) -> None:
5060
_endpoint = "{endpoint}"
51-
_cloud = kwargs.pop("cloud_setting", None) or settings.current.azure_cloud # type: ignore
61+
_cloud = cloud_setting or settings.current.azure_cloud # type: ignore
5262
_endpoints = get_arm_endpoints(_cloud)
5363
if not base_url:
5464
base_url = _endpoints["resource_manager"]
@@ -57,6 +67,7 @@ def __init__(
5767
credential=credential,
5868
subscription_id=subscription_id,
5969
base_url=cast(str, base_url),
70+
cloud_setting=cloud_setting,
6071
credential_scopes=credential_scopes,
6172
**kwargs
6273
)

sdk/planetarycomputer/azure-mgmt-planetarycomputer/azure/mgmt/planetarycomputer/_configuration.py

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

9-
from typing import Any, TYPE_CHECKING
9+
from typing import Any, Optional, TYPE_CHECKING
1010

1111
from azure.core.pipeline import policies
1212
from azure.mgmt.core.policies import ARMChallengeAuthenticationPolicy, ARMHttpLoggingPolicy
1313

1414
from ._version import VERSION
1515

1616
if TYPE_CHECKING:
17+
from azure.core import AzureClouds
1718
from azure.core.credentials import TokenCredential
1819

1920

@@ -29,9 +30,12 @@ class PlanetaryComputerMgmtClientConfiguration: # pylint: disable=too-many-inst
2930
:type subscription_id: str
3031
:param base_url: Service host. Default value is "https://management.azure.com".
3132
:type base_url: str
32-
:keyword api_version: The API version to use for this operation. Default value is
33-
"2025-02-11-preview". Note that overriding this default value may result in unsupported
34-
behavior.
33+
:param cloud_setting: The cloud setting for which to get the ARM endpoint. Default value is
34+
None.
35+
:type cloud_setting: ~azure.core.AzureClouds
36+
:keyword api_version: The API version to use for this operation. Known values are "2026-04-15".
37+
Default value is "2026-04-15". Note that overriding this default value may result in
38+
unsupported behavior.
3539
:paramtype api_version: str
3640
"""
3741

@@ -40,9 +44,10 @@ def __init__(
4044
credential: "TokenCredential",
4145
subscription_id: str,
4246
base_url: str = "https://management.azure.com",
47+
cloud_setting: Optional["AzureClouds"] = None,
4348
**kwargs: Any
4449
) -> None:
45-
api_version: str = kwargs.pop("api_version", "2025-02-11-preview")
50+
api_version: str = kwargs.pop("api_version", "2026-04-15")
4651

4752
if credential is None:
4853
raise ValueError("Parameter 'credential' must not be None.")
@@ -52,6 +57,7 @@ def __init__(
5257
self.credential = credential
5358
self.subscription_id = subscription_id
5459
self.base_url = base_url
60+
self.cloud_setting = cloud_setting
5561
self.api_version = api_version
5662
self.credential_scopes = kwargs.pop("credential_scopes", ["https://management.azure.com/.default"])
5763
kwargs.setdefault("sdk_moniker", "mgmt-planetarycomputer/{}".format(VERSION))

sdk/planetarycomputer/azure-mgmt-planetarycomputer/azure/mgmt/planetarycomputer/_patch.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
88
Follow our quickstart for examples: https://aka.ms/azsdk/python/dpcodegen/python/customize
99
"""
10-
from typing import List
1110

12-
__all__: List[str] = [] # Add all objects you want publicly available to users at this package level
11+
12+
__all__: list[str] = [] # Add all objects you want publicly available to users at this package level
1313

1414

1515
def patch_sdk():

0 commit comments

Comments
 (0)