Skip to content

Commit a4e85b2

Browse files
msyyctadelesh
andauthored
* Update dependencies (2025-04-23 03:11:06) * Regenerate for typespec-python (2025-04-23 03:15:43) * update * bump version * remove --------- Co-authored-by: AutoPrFromHttpClientPython <AutoPrFromHttpClientPython> Co-authored-by: Chenjie Shi <tadelesh.shi@live.cn>
1 parent e353d51 commit a4e85b2

64 files changed

Lines changed: 5456 additions & 298 deletions

Some content is hidden

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

packages/autorest.python/CHANGELOG.md

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

3+
## 6.34.1
4+
5+
### Bump dependencies
6+
7+
- Bump to latest typespec version
8+
9+
310
## 6.34.0
411

512
### Bug Fixes

packages/autorest.python/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@autorest/python",
3-
"version": "6.34.0",
3+
"version": "6.34.1",
44
"description": "The Python extension for generators in AutoRest.",
55
"scripts": {
66
"start": "node ./scripts/run-python3.js ./scripts/start.py",
@@ -29,7 +29,7 @@
2929
},
3030
"homepage": "https://github.com/Azure/autorest.python/blob/main/README.md",
3131
"dependencies": {
32-
"@typespec/http-client-python": "~0.11.1",
32+
"@typespec/http-client-python": "~0.11.2",
3333
"@autorest/system-requirements": "~1.0.2",
3434
"fs-extra": "~11.2.0",
3535
"tsx": "~4.19.1"

packages/typespec-python/CHANGELOG.md

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

3+
## 0.44.1
4+
5+
### Bump dependencies
6+
7+
- Bump to latest typespec version
8+
9+
310
## 0.44.0
411

512
### Bug Fixes

packages/typespec-python/package.json

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@azure-tools/typespec-python",
3-
"version": "0.44.0",
3+
"version": "0.44.1",
44
"author": "Microsoft Corporation",
55
"description": "TypeSpec emitter for Python SDKs",
66
"homepage": "https://github.com/Azure/autorest.python",
@@ -45,45 +45,45 @@
4545
"generator/**"
4646
],
4747
"peerDependencies": {
48-
"@typespec/compiler": "^1.0.0-0",
49-
"@typespec/http": "^1.0.0-0",
50-
"@typespec/rest": ">=0.68.0 <1.0.0",
51-
"@typespec/versioning": ">=0.68.0 <1.0.0",
52-
"@typespec/openapi": "^1.0.0-0",
53-
"@typespec/events": ">=0.68.0 <1.0.0",
54-
"@typespec/sse": ">=0.68.0 <1.0.0",
55-
"@typespec/streams": ">=0.68.0 <1.0.0",
56-
"@typespec/xml": ">=0.68.0 <1.0.0",
57-
"@azure-tools/typespec-azure-core": ">=0.54.0 <1.0.0",
58-
"@azure-tools/typespec-azure-resource-manager": ">=0.54.0 <1.0.0",
59-
"@azure-tools/typespec-autorest": ">=0.54.0 <1.0.0",
60-
"@azure-tools/typespec-azure-rulesets": ">=0.54.0 <1.0.0",
61-
"@azure-tools/typespec-client-generator-core": ">=0.54.2 <1.0.0"
48+
"@typespec/compiler": "^1.0.0-rc.1",
49+
"@typespec/http": "^1.0.0-rc.1",
50+
"@typespec/rest": ">=0.69.0 <1.0.0",
51+
"@typespec/versioning": ">=0.69.0 <1.0.0",
52+
"@typespec/openapi": "^1.0.0-rc.1",
53+
"@typespec/events": ">=0.69.0 <1.0.0",
54+
"@typespec/sse": ">=0.69.0 <1.0.0",
55+
"@typespec/streams": ">=0.69.0 <1.0.0",
56+
"@typespec/xml": ">=0.69.0 <1.0.0",
57+
"@azure-tools/typespec-azure-core": ">=0.55.0 <1.0.0",
58+
"@azure-tools/typespec-azure-resource-manager": ">=0.55.0 <1.0.0",
59+
"@azure-tools/typespec-autorest": ">=0.55.0 <1.0.0",
60+
"@azure-tools/typespec-azure-rulesets": ">=0.55.0 <1.0.0",
61+
"@azure-tools/typespec-client-generator-core": ">=0.55.0 <1.0.0"
6262
},
6363
"dependencies": {
6464
"js-yaml": "~4.1.0",
6565
"semver": "~7.6.2",
6666
"tsx": "~4.19.1",
67-
"@typespec/http-client-python": "~0.11.1",
67+
"@typespec/http-client-python": "~0.11.2",
6868
"fs-extra": "~11.2.0"
6969
},
7070
"devDependencies": {
71-
"@typespec/compiler": "^1.0.0-0",
72-
"@typespec/http": "^1.0.0-0",
73-
"@typespec/rest": "~0.68.0",
74-
"@typespec/versioning": "~0.68.0",
75-
"@typespec/openapi": "^1.0.0-0",
76-
"@typespec/events": "~0.68.0",
77-
"@typespec/sse": "~0.68.0",
78-
"@typespec/streams": "~0.68.0",
79-
"@typespec/xml": "~0.68.0",
80-
"@azure-tools/typespec-azure-resource-manager": "~0.54.0",
81-
"@azure-tools/typespec-azure-core": "~0.54.0",
82-
"@azure-tools/typespec-azure-rulesets": "~0.54.0",
83-
"@azure-tools/typespec-autorest": "~0.54.0",
84-
"@azure-tools/typespec-client-generator-core": "~0.54.2",
85-
"@azure-tools/azure-http-specs": "0.1.0-alpha.14",
86-
"@typespec/http-specs": "0.1.0-alpha.19",
71+
"@typespec/compiler": "^1.0.0-rc.1",
72+
"@typespec/http": "^1.0.0-rc.1",
73+
"@typespec/rest": "~0.69.0",
74+
"@typespec/versioning": "~0.69.0",
75+
"@typespec/openapi": "^1.0.0-rc.1",
76+
"@typespec/events": "~0.69.0",
77+
"@typespec/sse": "~0.69.0",
78+
"@typespec/streams": "~0.69.0",
79+
"@typespec/xml": "~0.69.0",
80+
"@azure-tools/typespec-azure-resource-manager": "~0.55.0",
81+
"@azure-tools/typespec-azure-core": "~0.55.0",
82+
"@azure-tools/typespec-azure-rulesets": "~0.55.0",
83+
"@azure-tools/typespec-autorest": "~0.55.0",
84+
"@azure-tools/typespec-client-generator-core": "~0.55.0",
85+
"@azure-tools/azure-http-specs": "0.1.0-alpha.15",
86+
"@typespec/http-specs": "0.1.0-alpha.20",
8787
"@types/js-yaml": "~4.0.5",
8888
"@types/node": "~22.13.14",
8989
"@types/yargs": "~17.0.33",

packages/typespec-python/scripts/eng/mypy.ini

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# global configurations
22
[mypy]
33
python_version = 3.9
4+
# Exclude mypy check for sub client tests
5+
exclude = (azure/clientgenerator/core/clientinitialization/operations/_operations\.py|azure/clientgenerator/core/clientinitialization/aio/operations/_operations\.py)
46

57

68
# module level configurations

packages/typespec-python/scripts/eng/regenerate.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ const AZURE_EMITTER_OPTIONS: Record<string, Record<string, string> | Record<stri
2929
"azure/client-generator-core/client-initialization": {
3030
namespace: "specs.azure.clientgenerator.core.clientinitialization",
3131
},
32+
"azure/client-generator-core/deserialize-empty-string-as-null": {
33+
namespace: "specs.azure.clientgenerator.core.emptystring",
34+
},
3235
"azure/client-generator-core/flatten-property": {
3336
namespace: "specs.azure.clientgenerator.core.flattenproperty",
3437
},

packages/typespec-python/test/azure/generated/azure-client-generator-core-client-initialization/apiview-properties.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,12 @@
2525
"specs.azure.clientgenerator.core.clientinitialization.ParamAliasClient.with_aliased_name": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParamAlias.withAliasedName",
2626
"specs.azure.clientgenerator.core.clientinitialization.aio.ParamAliasClient.with_aliased_name": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParamAlias.withAliasedName",
2727
"specs.azure.clientgenerator.core.clientinitialization.ParamAliasClient.with_original_name": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParamAlias.withOriginalName",
28-
"specs.azure.clientgenerator.core.clientinitialization.aio.ParamAliasClient.with_original_name": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParamAlias.withOriginalName"
28+
"specs.azure.clientgenerator.core.clientinitialization.aio.ParamAliasClient.with_original_name": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParamAlias.withOriginalName",
29+
"specs.azure.clientgenerator.core.clientinitialization.operations.ChildClientOperations.with_query": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParentClient.ChildClient.withQuery",
30+
"specs.azure.clientgenerator.core.clientinitialization.aio.operations.ChildClientOperations.with_query": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParentClient.ChildClient.withQuery",
31+
"specs.azure.clientgenerator.core.clientinitialization.operations.ChildClientOperations.get_standalone": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParentClient.ChildClient.getStandalone",
32+
"specs.azure.clientgenerator.core.clientinitialization.aio.operations.ChildClientOperations.get_standalone": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParentClient.ChildClient.getStandalone",
33+
"specs.azure.clientgenerator.core.clientinitialization.operations.ChildClientOperations.delete_standalone": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParentClient.ChildClient.deleteStandalone",
34+
"specs.azure.clientgenerator.core.clientinitialization.aio.operations.ChildClientOperations.delete_standalone": "_Specs_.Azure.ClientGeneratorCore.ClientInitialization.ParentClient.ChildClient.deleteStandalone"
2935
}
3036
}

packages/typespec-python/test/azure/generated/azure-client-generator-core-client-initialization/generated_tests/conftest.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,15 @@ def add_sanitizers(test_proxy):
7070
add_general_regex_sanitizer(regex=paramalias_client_id, value="00000000-0000-0000-0000-000000000000")
7171
add_general_regex_sanitizer(regex=paramalias_client_secret, value="00000000-0000-0000-0000-000000000000")
7272

73+
parent_subscription_id = os.environ.get("PARENT_SUBSCRIPTION_ID", "00000000-0000-0000-0000-000000000000")
74+
parent_tenant_id = os.environ.get("PARENT_TENANT_ID", "00000000-0000-0000-0000-000000000000")
75+
parent_client_id = os.environ.get("PARENT_CLIENT_ID", "00000000-0000-0000-0000-000000000000")
76+
parent_client_secret = os.environ.get("PARENT_CLIENT_SECRET", "00000000-0000-0000-0000-000000000000")
77+
add_general_regex_sanitizer(regex=parent_subscription_id, value="00000000-0000-0000-0000-000000000000")
78+
add_general_regex_sanitizer(regex=parent_tenant_id, value="00000000-0000-0000-0000-000000000000")
79+
add_general_regex_sanitizer(regex=parent_client_id, value="00000000-0000-0000-0000-000000000000")
80+
add_general_regex_sanitizer(regex=parent_client_secret, value="00000000-0000-0000-0000-000000000000")
81+
7382
add_header_regex_sanitizer(key="Set-Cookie", value="[set-cookie;]")
7483
add_header_regex_sanitizer(key="Cookie", value="cookie;")
7584
add_body_key_sanitizer(json_path="$..access_token", value="access_token")
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# 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) Python Code Generator.
6+
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
# --------------------------------------------------------------------------
8+
import pytest
9+
from devtools_testutils import recorded_by_proxy
10+
from testpreparer import ParentClientTestBase, ParentPreparer
11+
12+
13+
@pytest.mark.skip("you may need to update the auto-generated test case before run it")
14+
class TestParentChildClientOperations(ParentClientTestBase):
15+
@ParentPreparer()
16+
@recorded_by_proxy
17+
def test_child_client_with_query(self, parent_endpoint):
18+
client = self.create_client(endpoint=parent_endpoint)
19+
response = client.child_client.with_query()
20+
21+
# please add some check logic here by yourself
22+
# ...
23+
24+
@ParentPreparer()
25+
@recorded_by_proxy
26+
def test_child_client_get_standalone(self, parent_endpoint):
27+
client = self.create_client(endpoint=parent_endpoint)
28+
response = client.child_client.get_standalone()
29+
30+
# please add some check logic here by yourself
31+
# ...
32+
33+
@ParentPreparer()
34+
@recorded_by_proxy
35+
def test_child_client_delete_standalone(self, parent_endpoint):
36+
client = self.create_client(endpoint=parent_endpoint)
37+
response = client.child_client.delete_standalone()
38+
39+
# please add some check logic here by yourself
40+
# ...
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# 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) Python Code Generator.
6+
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
# --------------------------------------------------------------------------
8+
import pytest
9+
from devtools_testutils.aio import recorded_by_proxy_async
10+
from testpreparer import ParentPreparer
11+
from testpreparer_async import ParentClientTestBaseAsync
12+
13+
14+
@pytest.mark.skip("you may need to update the auto-generated test case before run it")
15+
class TestParentChildClientOperationsAsync(ParentClientTestBaseAsync):
16+
@ParentPreparer()
17+
@recorded_by_proxy_async
18+
async def test_child_client_with_query(self, parent_endpoint):
19+
client = self.create_async_client(endpoint=parent_endpoint)
20+
response = await client.child_client.with_query()
21+
22+
# please add some check logic here by yourself
23+
# ...
24+
25+
@ParentPreparer()
26+
@recorded_by_proxy_async
27+
async def test_child_client_get_standalone(self, parent_endpoint):
28+
client = self.create_async_client(endpoint=parent_endpoint)
29+
response = await client.child_client.get_standalone()
30+
31+
# please add some check logic here by yourself
32+
# ...
33+
34+
@ParentPreparer()
35+
@recorded_by_proxy_async
36+
async def test_child_client_delete_standalone(self, parent_endpoint):
37+
client = self.create_async_client(endpoint=parent_endpoint)
38+
response = await client.child_client.delete_standalone()
39+
40+
# please add some check logic here by yourself
41+
# ...

0 commit comments

Comments
 (0)