diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 62f532dd7473..691dbc38fc6a 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -184,10 +184,10 @@ # ServiceLabel: %Cosmos # PRLabel: %Cosmos -/sdk/cosmos/ @kushagraThapar @simorenoh @xinlian12 @annatisch @bambriz +/sdk/cosmos/ @kushagraThapar @simorenoh @xinlian12 @annatisch @bambriz @pilchie # ServiceLabel: %Cosmos %Service Attention -#// @pjohari-ms @simorenoh @AbhinavTrips @bambriz +#// @pjohari-ms @simorenoh @AbhinavTrips @bambriz @pilchie # PRLabel: %Data Factory /sdk/datafactory/ @hvermis diff --git a/eng/emitter-package-lock.json b/eng/emitter-package-lock.json index af1f60521ab2..c022e77a9041 100644 --- a/eng/emitter-package-lock.json +++ b/eng/emitter-package-lock.json @@ -5,13 +5,12 @@ "packages": { "": { "dependencies": { - "@azure-tools/typespec-python": "0.23.12" + "@azure-tools/typespec-python": "0.23.13" }, "devDependencies": { "@azure-tools/typespec-autorest": "~0.42.0", "@azure-tools/typespec-azure-core": "~0.42.0", - "@azure-tools/typespec-azure-resource-manager": "~0.42.1", - "@azure-tools/typespec-azure-rulesets": "~0.42.1", + "@azure-tools/typespec-azure-resource-manager": "~0.42.0", "@azure-tools/typespec-client-generator-core": "~0.42.3", "@typespec/compiler": "~0.56.0", "@typespec/http": "~0.56.0", @@ -21,9 +20,9 @@ } }, "node_modules/@autorest/python": { - "version": "6.13.17", - "resolved": "https://registry.npmjs.org/@autorest/python/-/python-6.13.17.tgz", - "integrity": "sha512-LFqAZz08bssfcFP+AXFkFmD6vgmoSe05WRIRrPW2vK+lXNloDx4PixdoCJ8JsEi1Bkzm6NhS64nCAe/ogoqp7g==", + "version": "6.13.18", + "resolved": "https://registry.npmjs.org/@autorest/python/-/python-6.13.18.tgz", + "integrity": "sha512-NkuUMeffb00s5nN68/LKOz3rY7+VehVVTcAO5YRecV1Gety64omopYSxVs8G2bXjlfkRC5qGQZ4WZM3XAb5EYw==", "hasInstallScript": true, "dependencies": { "@autorest/system-requirements": "~1.0.2" @@ -96,21 +95,6 @@ "@typespec/versioning": "~0.56.0" } }, - "node_modules/@azure-tools/typespec-azure-rulesets": { - "version": "0.42.1", - "resolved": "https://registry.npmjs.org/@azure-tools/typespec-azure-rulesets/-/typespec-azure-rulesets-0.42.1.tgz", - "integrity": "sha512-GRiMErWJ96DvDBQMVgGI1sgMTOegXxpx7w6enZyEF0BaodxGfObJyl1TrMb9Pj6NAZfV5Q6uJAfXFbpF1MVDCw==", - "dev": true, - "engines": { - "node": ">=18.0.0" - }, - "peerDependencies": { - "@azure-tools/typespec-azure-core": "~0.42.0", - "@azure-tools/typespec-azure-resource-manager": "~0.42.1", - "@azure-tools/typespec-client-generator-core": "~0.42.3", - "@typespec/compiler": "~0.56.0" - } - }, "node_modules/@azure-tools/typespec-client-generator-core": { "version": "0.42.3", "resolved": "https://registry.npmjs.org/@azure-tools/typespec-client-generator-core/-/typespec-client-generator-core-0.42.3.tgz", @@ -132,11 +116,11 @@ } }, "node_modules/@azure-tools/typespec-python": { - "version": "0.23.12", - "resolved": "https://registry.npmjs.org/@azure-tools/typespec-python/-/typespec-python-0.23.12.tgz", - "integrity": "sha512-xkXcdvsb5xm7rJivo5VMh5pOamgW+ou3dVFLtyz9nlEtliWQLYjzqDcni8MNXERueOr2/lHynpUzNS2bnfcteA==", + "version": "0.23.13", + "resolved": "https://registry.npmjs.org/@azure-tools/typespec-python/-/typespec-python-0.23.13.tgz", + "integrity": "sha512-UCy/zxgJahYcLEVtzqO9D0ijde+K5+H/xySWZxaJIw/DUU/if5JBsgK8KRBgL4fSj0quwlH2zrvoPifz56UWyg==", "dependencies": { - "@autorest/python": "^6.13.17", + "@autorest/python": "^6.13.18", "@typespec/openapi3": "~0.56.0", "js-yaml": "~4.1.0" }, diff --git a/eng/emitter-package.json b/eng/emitter-package.json index 64ae99d004c6..3df3d426ce25 100644 --- a/eng/emitter-package.json +++ b/eng/emitter-package.json @@ -1,18 +1,17 @@ { "main": "dist/src/index.js", "dependencies": { - "@azure-tools/typespec-python": "0.23.12" + "@azure-tools/typespec-python": "0.23.13" }, "devDependencies": { - "@typespec/http": "~0.56.0", - "@typespec/openapi": "~0.56.0", - "@azure-tools/typespec-azure-resource-manager": "~0.42.1", - "@azure-tools/typespec-azure-rulesets": "~0.42.1", - "@typespec/versioning": "~0.56.0", - "@azure-tools/typespec-azure-core": "~0.42.0", "@azure-tools/typespec-autorest": "~0.42.0", + "@azure-tools/typespec-azure-core": "~0.42.0", + "@azure-tools/typespec-azure-resource-manager": "~0.42.0", "@azure-tools/typespec-client-generator-core": "~0.42.3", + "@typespec/compiler": "~0.56.0", + "@typespec/http": "~0.56.0", + "@typespec/openapi": "~0.56.0", "@typespec/rest": "~0.56.0", - "@typespec/compiler": "~0.56.0" + "@typespec/versioning": "~0.56.0" } } diff --git a/eng/pipelines/docindex.yml b/eng/pipelines/docindex.yml index 3b8be4f47740..59aee791b36e 100644 --- a/eng/pipelines/docindex.yml +++ b/eng/pipelines/docindex.yml @@ -159,14 +159,18 @@ jobs: ScriptDirectory: $(Build.SourcesDirectory)/eng/common/scripts PushArgs: -f - - task: PowerShell@2 + - task: AzureCLI@2 displayName: Queue Docs CI build inputs: - pwsh: true - filePath: eng/common/scripts/Queue-Pipeline.ps1 - arguments: > - -Organization "apidrop" - -Project "Content%20CI" - -DefinitionId 5533 - -AuthToken "$(azuresdk-apidrop-devops-queue-build-pat)" - -BuildParametersJson (@{ params = (Get-Content ./eng/dailydocsconfig.json -Raw) -replace '%%DailyDocsBranchName%%', "$(DailyDocsBranchName)" } | ConvertTo-Json) + azureSubscription: msdocs-apidrop-connection + scriptType: pscore + scriptLocation: inlineScript + inlineScript: | + $accessToken = az account get-access-token --resource "499b84ac-1321-427f-aa17-267ca6975798" --query "accessToken" --output tsv + $buildParamJson = (@{ params = (Get-Content ./eng/dailydocsconfig.json -Raw) -replace '%%DailyDocsBranchName%%', "$(DailyDocsBranchName)" } | ConvertTo-Json) + eng/common/scripts/Queue-Pipeline.ps1 ` + -Organization "apidrop" ` + -Project "Content%20CI" ` + -DefinitionId 5533 ` + -BuildParametersJson $buildParamJson ` + -BearerToken $accessToken diff --git a/sdk/core/corehttp/corehttp/rest/_aiohttp.py b/sdk/core/corehttp/corehttp/rest/_aiohttp.py index d6f984a29044..8fc027b9a1f7 100644 --- a/sdk/core/corehttp/corehttp/rest/_aiohttp.py +++ b/sdk/core/corehttp/corehttp/rest/_aiohttp.py @@ -30,7 +30,7 @@ from itertools import groupby from typing import Iterator, cast, TYPE_CHECKING from multidict import CIMultiDict -import aiohttp.client_exceptions # pylint: disable=all +import aiohttp.client_exceptions # pylint: disable=networking-import-outside-azure-core-transport from ._http_response_impl_async import AsyncHttpResponseImpl from ..exceptions import ( diff --git a/sdk/core/corehttp/corehttp/rest/_http_response_impl.py b/sdk/core/corehttp/corehttp/rest/_http_response_impl.py index 8ce06c821552..34ce58a56dd1 100644 --- a/sdk/core/corehttp/corehttp/rest/_http_response_impl.py +++ b/sdk/core/corehttp/corehttp/rest/_http_response_impl.py @@ -292,12 +292,7 @@ def iter_bytes(self, **kwargs) -> Iterator[bytes]: yield self.content[i : i + chunk_size] else: self._stream_download_check() - for part in self._stream_download_generator( - response=self, - pipeline=None, - decompress=True, - ): - yield part + yield from self._stream_download_generator(response=self, pipeline=None, decompress=True) self.close() def iter_raw(self, **kwargs) -> Iterator[bytes]: @@ -307,6 +302,5 @@ def iter_raw(self, **kwargs) -> Iterator[bytes]: :rtype: Iterator[str] """ self._stream_download_check() - for part in self._stream_download_generator(response=self, pipeline=None, decompress=False): - yield part + yield from self._stream_download_generator(response=self, pipeline=None, decompress=False) self.close() diff --git a/sdk/core/corehttp/corehttp/rest/_requests_basic.py b/sdk/core/corehttp/corehttp/rest/_requests_basic.py index c3fe46ea570f..f180f735d10e 100644 --- a/sdk/core/corehttp/corehttp/rest/_requests_basic.py +++ b/sdk/core/corehttp/corehttp/rest/_requests_basic.py @@ -27,8 +27,8 @@ import logging import collections.abc as collections from typing import TYPE_CHECKING, Any -import requests # pylint: disable=all -from requests.structures import CaseInsensitiveDict # pylint: disable=all +import requests # pylint: disable=networking-import-outside-azure-core-transport +from requests.structures import CaseInsensitiveDict # pylint: disable=networking-import-outside-azure-core-transport from urllib3.exceptions import ( DecodeError as CoreDecodeError, ReadTimeoutError, @@ -172,8 +172,7 @@ def _read_raw_stream(response, chunk_size=1): # Special case for urllib3. if hasattr(response.raw, "stream"): try: - for chunk in response.raw.stream(chunk_size, decode_content=False): - yield chunk + yield from response.raw.stream(chunk_size, decode_content=False) except ProtocolError as e: raise ServiceResponseError(e, error=e) from e except CoreDecodeError as e: diff --git a/sdk/core/corehttp/corehttp/transport/aiohttp/_aiohttp.py b/sdk/core/corehttp/corehttp/transport/aiohttp/_aiohttp.py index 93f5822d8c56..6decaddf4dd8 100644 --- a/sdk/core/corehttp/corehttp/transport/aiohttp/_aiohttp.py +++ b/sdk/core/corehttp/corehttp/transport/aiohttp/_aiohttp.py @@ -29,8 +29,8 @@ import logging import asyncio -import aiohttp # pylint: disable=all -import aiohttp.client_exceptions # pylint: disable=all +import aiohttp # pylint: disable=networking-import-outside-azure-core-transport +import aiohttp.client_exceptions # pylint: disable=networking-import-outside-azure-core-transport from ...exceptions import ( ServiceRequestError, diff --git a/sdk/core/corehttp/corehttp/transport/requests/_bigger_block_size_http_adapters.py b/sdk/core/corehttp/corehttp/transport/requests/_bigger_block_size_http_adapters.py index 61f32d5dac0e..85cf292d6c83 100644 --- a/sdk/core/corehttp/corehttp/transport/requests/_bigger_block_size_http_adapters.py +++ b/sdk/core/corehttp/corehttp/transport/requests/_bigger_block_size_http_adapters.py @@ -27,7 +27,7 @@ import sys from typing import MutableMapping, Optional -from requests.adapters import HTTPAdapter # pylint: disable=all +from requests.adapters import HTTPAdapter # pylint: disable=networking-import-outside-azure-core-transport from urllib3.connectionpool import ConnectionPool diff --git a/sdk/core/corehttp/corehttp/transport/requests/_requests_basic.py b/sdk/core/corehttp/corehttp/transport/requests/_requests_basic.py index 24d820c475a7..73c6eeffee03 100644 --- a/sdk/core/corehttp/corehttp/transport/requests/_requests_basic.py +++ b/sdk/core/corehttp/corehttp/transport/requests/_requests_basic.py @@ -31,7 +31,7 @@ NewConnectionError, ConnectTimeoutError, ) -import requests # pylint: disable=all +import requests # pylint: disable=networking-import-outside-azure-core-transport from ...exceptions import ( ServiceRequestError, diff --git a/sdk/eventgrid/test-resources.json b/sdk/eventgrid/test-resources.json index 46be17ef3e17..92d9078abce6 100644 --- a/sdk/eventgrid/test-resources.json +++ b/sdk/eventgrid/test-resources.json @@ -20,14 +20,7 @@ "metadata": { "description": "The application client ID used to run tests." } - }, - "testApplicationSecret": { - "type": "string", - "metadata": { - "description": "The application client secret used to run tests." - } - }, - + } }, "variables": { "namespaceName": "[format('{0}-2', parameters('baseName'))]", diff --git a/sdk/eventgrid/tests.yml b/sdk/eventgrid/tests.yml index cf20c2c1580a..533a10696214 100644 --- a/sdk/eventgrid/tests.yml +++ b/sdk/eventgrid/tests.yml @@ -6,19 +6,10 @@ extends: ServiceDirectory: eventgrid BuildTargetingString: azure-eventgrid* Location: eastus + UseFederatedAuth: true MatrixReplace: - TestSamples=.*/true EnvVars: TEST_MODE: 'RunLiveNoRecord' AZURE_TEST_RUN_LIVE: 'true' - AZURE_SKIP_LIVE_RECORDING: 'True' - AZURE_STORAGE_CONNECTION_STRING: $(python-storage-blob-connection-string) - AZURE_SUBSCRIPTION_ID: $(azure-subscription-id) - AZURE_TENANT_ID: $(aad-azure-sdk-test-tenant-id) - AZURE_CLIENT_ID: $(aad-azure-sdk-test-client-id) - AZURE_CLIENT_SECRET: $(aad-azure-sdk-test-client-secret) - EVENTGRID_SAS: $(python-sdk-test-eg-sas) - STORAGE_QUEUE_NAME: $(python-storage-queue-name) - EVENTGRID_PARTNER_NAMESPACE_TOPIC_ENDPOINT: $(python-eventgrid-partner-endpoint) - EVENTGRID_PARTNER_NAMESPACE_TOPIC_KEY: $(python-eventgrid-partner-key) - EVENTGRID_PARTNER_CHANNEL_NAME: $(python-eventgrid-partner-channel-name) + AZURE_SKIP_LIVE_RECORDING: 'True' \ No newline at end of file diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/job.py b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/job.py index 9550fcff30ae..6d4dc5f8c7b0 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/job.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/job.py @@ -306,9 +306,13 @@ def _from_rest_object( # pylint: disable=too-many-return-statements return ImportJob._load_from_rest(obj) res_command: Job = Command._load_from_rest_job(obj) + if hasattr(obj, "name"): + res_command._name = obj.name # type: ignore[attr-defined] return res_command if obj.properties.job_type == RestJobType.SPARK: res_spark: Job = Spark._load_from_rest_job(obj) + if hasattr(obj, "name"): + res_spark._name = obj.name # type: ignore[attr-defined] return res_spark if obj.properties.job_type == RestJobType.SWEEP: return SweepJob._load_from_rest(obj) diff --git a/sdk/monitor/azure-monitor-opentelemetry/CHANGELOG.md b/sdk/monitor/azure-monitor-opentelemetry/CHANGELOG.md index 2cb7d47de936..f2050b7e5b4b 100644 --- a/sdk/monitor/azure-monitor-opentelemetry/CHANGELOG.md +++ b/sdk/monitor/azure-monitor-opentelemetry/CHANGELOG.md @@ -1,18 +1,12 @@ # Release History -## 1.4.3 (Unreleased) +## 1.5.0 (2024-05-31) ### Features Added - Enable live metrics feature ([#35566](https://github.com/Azure/azure-sdk-for-python/pull/35566)) -### Breaking Changes - -### Bugs Fixed - -### Other Changes - ## 1.4.2 (2024-05-20) ### Features Added diff --git a/sdk/monitor/azure-monitor-opentelemetry/azure/monitor/opentelemetry/_version.py b/sdk/monitor/azure-monitor-opentelemetry/azure/monitor/opentelemetry/_version.py index a5c8ef470e08..7ece5b3e5b33 100644 --- a/sdk/monitor/azure-monitor-opentelemetry/azure/monitor/opentelemetry/_version.py +++ b/sdk/monitor/azure-monitor-opentelemetry/azure/monitor/opentelemetry/_version.py @@ -4,4 +4,4 @@ # license information. # -------------------------------------------------------------------------- -VERSION = "1.4.3" +VERSION = "1.5.0" diff --git a/sdk/monitor/azure-monitor-opentelemetry/setup.py b/sdk/monitor/azure-monitor-opentelemetry/setup.py index 557f9f487fdb..cf8e66da403c 100644 --- a/sdk/monitor/azure-monitor-opentelemetry/setup.py +++ b/sdk/monitor/azure-monitor-opentelemetry/setup.py @@ -87,7 +87,7 @@ install_requires=[ "azure-core<2.0.0,>=1.28.0", "azure-core-tracing-opentelemetry~=1.0.0b11", - "azure-monitor-opentelemetry-exporter~=1.0.0b25", + "azure-monitor-opentelemetry-exporter~=1.0.0b26", "opentelemetry-instrumentation-django~=0.42b0", "opentelemetry-instrumentation-fastapi~=0.42b0", "opentelemetry-instrumentation-flask~=0.42b0",