-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
correct perf-send-to-helix on windows #42235
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, thanks for fixing this!
@@ -24,7 +24,7 @@ parameters: | |||
steps: | |||
- template: /eng/pipelines/common/templates/runtimes/send-to-helix-inner-step.yml | |||
parameters: | |||
osGroup: $(Agent.Os) | |||
osGroup: $(Agent.OS) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
YAML identifiers should be case insensitive. I think you need to use variables['Agent.Os'] but use a different substitution syntax. I'll look it up after our team meeting, I think it's something like
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible if we directly use this variable as variables['Agent.Os']
in
- ${{ if eq(parameters.osGroup, 'Windows_NT') }}: |
instead of passing it as a parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it should be $[ variables('Agent.Os') ], at least I hope so
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, the problem is that the inner-step is called from three different scripts, we would need to double-check that variables['Agent.Os'] work everywhere, it can likely break for cross-targeting builds.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for sending the doc! I'll test $[ variables('Agent.Os') ]
first
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From the log it seems the $[ variables['Agent.Os'] ]
is not expanded before evaluating the condition:
Begin evaluating template '/eng/pipelines/common/templates/runtimes/send-to-helix-inner-step.yml'
Evaluating: eq(parameters['osGroup'], 'Windows_NT')
Expanded: eq('$[ variables[''Agent.Os''] ]', 'Windows_NT')
Result: False
Evaluating: ne(parameters['osGroup'], 'Windows_NT')
Expanded: ne('$[ variables[''Agent.Os''] ]', 'Windows_NT')
Result: True
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems that the problem is.. the variable won't be populated until runtime but the condition evaluation happens at compile time? I was thinking we might want to try using runtime expression here $[ ]
instead of compile expression
- ${{ if eq(parameters.osGroup, 'Windows_NT') }}: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I found another place that uses this condition
- ${{ if eq(parameters.osGroup, 'Windows_NT') }}: |
but in this case it works because the variable's ready at compile time
osGroup: Linux |
Looking at
|
We will see whether this will work in the current build. I suppose |
Works with |
Thanks so much Olivia for your perseverance in pushing this through! |
Just noticed arcade is not update with both commits ( 0956285 and this)... will submit both commits to arcade so they won't be overriden. |
@ooooolivia @trylek it looks like 0956285 didn't make it to arcade, only this PR. |
Missed updating non-perf changes in Arcade; new PR submitted in Arcade dotnet/arcade#6227 |
Fixing changes in this commit 0956285
Currently perf jobs on windows are running in bash and not being sent to helix.