Azure / Azure/azureml-examples

schema attribute "msi_resource_id" is not supported by code

Open
#3,697 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Jupyter Notebook
Stars
2k
Forks
1.7k
Avg merge
18h 18m
Merged PRs (30d)
2

Description

### Operating System

Linux

### Version Information

azure-cli: 2.78.0
azure-cli-core: 2.78.0
azure-cli-telemetry: 1.1.0
extensions:
azure-devops: 1.0.0
ml: 2.39.0

### Steps to reproduce

Write a YAML pipeline with the following text

pipeline.yaml

```
# Use managed identity to run the job
identity:
type: managed_identity
msi_resource_id: /subscriptions/xxxxxxxxxx/your-managed-identity
```

Run `az ml job validate --file pipeline.yaml` to verify

### Expected behavior

Verification should pass

### Actual behavior

Verificaiton failed
```
{
"errors": [
{
"message": "['TypeError: ManagedIdentityConfiguration.__init__() got an unexpected keyword argument \\'msi_resource_id\\'. Did you mean \\'resource_id\\'? from File \"/opt/az/azcliextensions/ml/azure/ai/ml/_schema/job/identity.py\", line 41, in make return ManagedIdentityConfiguration(**data)']; {'type': [\"Value 'managed_identity' passed is not in set ['aml_token']\"], 'msi_resource_id': ['Unknown field.']}; {'type': [\"Value 'managed_identity' passed is not in set ['user_identity']\"], 'msi_resource_id': ['Unknown field.']}",
"path": "identity",
"value": {
"msi_resource_id": "/subscriptions/xxxxxxxxxx/your-managed-identity",
"type": "managed_identity"
}
}
],
"result": "Failed"
}
```

### Addition information

Source code shows "msi_resource_id" is not supported.

https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_credentials.py#L512

Contributor guide

Open the contributing guide

Research direction

Start with the pipeline.yaml example in the issue and run `az ml job validate --file pipeline.yaml` to reproduce the failure. Inspect `azure/ai/ml/_schema/job/identity.py` at the reported `make` call and the linked `_credentials.py` section around line 512, then verify that validation accepts `msi_resource_id` as expected.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, python
Domain
cli, cloud, machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.