Visible rule and underscore values
gcacars opened this issue ยท 15 comments
I'm facing some problems with expressions in visibility rule that contains underscore in the values, like STANDARD_HA
.
Environment
azure-pipelines-task-lib version: 2.9.6
Issue Description
Values with underscore not pass in the extension validation.
Expected behaviour
Expression should be validated without errors.
Actual behaviour
Error: Extension validation failed.
Steps to reproduce
- Create a radio field:
{
"name": "tier",
"type": "radio",
"defaultValue": "BASIC",
"options": {
"BASIC": "standalone instance",
"STANDARD_HA": "highly available primary/replica instances"
}
}
- And other field with this visibleRule:
"visibleRule": "tier = STANDARD_HA"
- Package and publish the extension
Logs
Task definition visible rule \'tier = STANDARD_HA\' is invalid. It should be of format "A <validconditionhere> B" for Task with ID ...
This issue has had no activity in 90 days. Please comment if it is not actually stale
I also reported this to the product team and the rule on the marketplace is too strict. But I haven't seen a plan to resolve yet.
Ok, but not makes sense for me to have a marketplace rule in the value of a field. It differs from a task name or extension id...
I experienced the same problem when the value being tested has a #
. None of the options below work:
"visibleRule":"lang=C#"
"visibleRule":"lang = C#"
"visibleRule":"lang=\"C#\""
"visibleRule":"lang = \"C#\""
Got confirmation its a bug in the marketplace, but it's taking awfully long for the Azure Devops team to get the fix out.
If you manually push the task directly using tfx build tasks upload
, the task will work just fine.
This issue has had no activity in 90 days. Please comment if it is not actually stale
not stale
This issue has had no activity in 90 days. Please comment if it is not actually stale
not stale
This issue has had no activity in 90 days. Please comment if it is not actually stale
not stale
Looks like the marketplace has relaxed validation on visibleRule.
This is fixed now. Can be closed.
This issue has had no activity in 90 days. Please comment if it is not actually stale