You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[azure-ai-ml] Fix deployment_templates.get(name) resolving latest version (Bug 5402671) (#47975)
* Fix DeploymentTemplate get()/delete() sending literal "latest" as version
deployment_templates.get(name) with no version sent the literal "latest" in the version slot, which the service treats as a (nonexistent) label rather than "highest version", causing a 404 (DeploymentTemplate {name}:latest not found). The latest version is now resolved client-side by listing the available versions and selecting the highest (the service exposes no "latest" label and no server-side ordering). get() also accepts a `label` keyword (label="latest" resolves to the latest version) mirroring models.get(), so a Model allowedDeploymentTemplates .../labels/latest reference can be resolved; unsupported labels raise a clear error. delete(name) resolves the latest version the same way.
Bug 5402671
* Regenerate api.md and api.metadata.yml for new DeploymentTemplate.get label parameter
Adds the `label: Optional[str] = None` parameter to the DeploymentTemplate.get signature in the API surface snapshot and updates apiMdSha256 accordingly, so the API.md consistency CI check passes.
Copy file name to clipboardExpand all lines: sdk/ml/azure-ai-ml/CHANGELOG.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,6 +8,7 @@
8
8
- Fixed `MLClient.jobs.create_or_update`, `archive`, and `restore` failing for previously-fetched jobs across all job types by routing metadata-only edits through the RunHistory PATCH endpoint.
9
9
- Fixed `DeploymentTemplate.creation_context` always being `None` when retrieved via `get()` or `list()`. The created/modified timestamps and identity returned by the service (as `createdTime` / `modifiedTime` / `createdBy`) are now populated on `creation_context`, making `DeploymentTemplate` consistent with `Model` and `Environment`.
10
10
- Fixed `deployment_templates.list(name=...)` raising `AttributeError: 'str' object has no attribute 'request_timeout'`. In the list response, `requestSettings` / `livenessProbe` / `readinessProbe` arrive as stringified dicts nested under `properties`; these are now parsed before conversion, giving `list()` parity with `models.list()` / `environments.list()`.
11
+
- Fixed `deployment_templates.get(name)` failing with a 404 (`DeploymentTemplate {name}:latest not found`) when no version was supplied, because the literal string `"latest"` was sent as the version. The latest version is now resolved client-side (the service exposes no `latest` label and no server-side ordering), and `get()` accepts a `label` keyword (`label="latest"` resolves to the latest version) mirroring `models.get()`. `delete(name)` resolves the latest version the same way.
0 commit comments