microsoft / microsoft/AzureTRE
Error sending create / update request Unevaluated properties are not allowed ('your_property_name' was unexpected) occurs when updatable is false
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 235
- Forks
- 192
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 13
Description
Describe the bug
When trying to upgrade a resource that defines a property value from a parent in the upgrade step of the pipeline an error is generated because the properties are stripped out by the UI and not sent.
This causes the pipeline to get stuck and needs deleting from the cosmos DB
Error sending create / update request
Unevaluated properties are not allowed ('dc_ip_addresses' was unexpected)
Steps to reproduce
- Add a property that doesn't have updateable: true
- Update that property in the Upgrade pipeline
"log_analytics_workspace_name": {
"$id": "#/properties/log_analytics_workspace_name",
"type": "string",
"title": "Log Analytics Workspace Name"
}
"upgrade": [
{
"stepId": "main",
"properties": [
{
"name": "log_analytics_workspace_name",
"type": "string",
"value": "{{ resource.parent.properties.log_analytics_workspace_name }}"
}
]
},
- Try to update the service and see that the value is not sent which generates and error on the API and the resource is now infinitely updating and needs to be deleted from the cosmosDB.
Update
The solution is to set "updateable": true
I think the error is correct, trying to update a property that is not updatable however the real issue is that it causes the job to get stuck in the cosmosDB in the awaiting_update stage
There is also a need to document the use of the pipeline properties and the use of resource.parent.properties etc
Azure TRE release version (e.g. v0.14.0 or main):
main
Deployed Azure TRE components - click the (i) in the UI:
UI Version:
0.8.16
API Version:
0.25.0
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at ui/app/src/components/shared/create-update-resource/ResourceForm.tsx around line 103 and reproduce the upgrade pipeline with a non-updatable property inherited from resource.parent.properties. Trace the resulting API error and awaiting_update state, including the Cosmos DB record. Done means the failure no longer leaves the resource stuck, with the pipeline-property behavior documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, typescript
- Domain
- backend, cloud, database, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100