ci: Fix size check action to run on master #6248
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As pointed out by @AbhiPrasad, the size check action on CI has not been properly running since we merged #6180.
After some investigation, I think I've pinned the culprit down:
Basically, in that PR I "fixed" an
if
condition for the size limit action job. Previously, because the condition had a wrong syntax, it was always running.This was incorrect because either we need to wrap the whole expression with
${{ }}
, or none of it (asif
auto-wraps it). With the original statement, it always evaluated to a truthy expression.So I "fixed" the syntax, however didn't notice that one part of the check was incorrect:
Actually,
refs/heads/master/
never matches - the trailing/
is incorrect, I believe - should be:So this PR actually fixes that statement with the proper branch name (hopefully). Also, as far as I can tell from github docs, we don't actually need the
startsWith
stuff here.