mirror of
https://github.com/nektos/act.git
synced 2026-04-26 09:25:54 +03:00
[GH-ISSUE #2617] matrix cli parameter can't parse matrix values that have colons within #1188
Labels
No labels
area/action
area/cli
area/docs
area/image
area/runner
area/workflow
backlog
confirmed/not-planned
kind/bug
kind/discussion
kind/external
kind/feature-request
kind/question
meta/duplicate
meta/invalid
meta/need-more-info
meta/resolved
meta/wontfix
meta/workaround
needs-work
pull-request
review/not-planned
size/M
size/XL
size/XXL
stale
stale-exempt
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/act#1188
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Fryguy on GitHub (Jan 14, 2025).
Original GitHub issue: https://github.com/nektos/act/issues/2617
Bug report info
Command used with act
Describe issue
Our matrix is defined a below. However, because
:is the separator character on the command line for the--matrixand some of our matrix entries also use:, I can't specify the test-suite component. I was expecting a way to escape the:or have a different separator character, but I can't seem to find one.I tried running with both
--matrix 3.1:18:spec\:jestand--matrix 3.1:18:spec:jest, but neither work. I expect it to run the test suite specified, and then if it can't find it I expect it to fail saying it can't find that matrix entry. Instead, interestingly, act seems to run a random test suite, but sets up a service for every matrix entry anyway. So I have 14 services, but only one test-suite running which isn't the one I requested. Running multiple times seems to choose different test suites. Perhaps, it is running all of the suites, but since the services all bind to the same port only the first one "wins" - I do see an error at the very end that it can't bind to the service port.Link to GitHub repository
https://github.com/ManageIQ/manageiq-ui-classic
Workflow content
Relevant log output
Additional information
No response
@Andy4495 commented on GitHub (Jan 14, 2025):
I don't think you are specifying the matrix correctly on the command line. I didn't test your workflow, but I checked one of mine with a colon and it worked.
I think the matrix option you want to run is this:
(I don't think you need to specify
node-version, since there is only one choice in your matrix.)Also, you can run it with the verbose option
--verboseto see how act is evaluating the matrix parameters.@Fryguy commented on GitHub (Jan 14, 2025):
Ah now I understand - I misunderstood how the matrix parameter works and didn't realize you pass key/value pairs. That being said, the version you specified didn't work and I can't figure out the combo. I can't pass it with spaces between the values, because then it interprets the second value as a filter and I get
with quotes it seems to parse it incorrectly:
Notice that it seems to take the
ruby-version:part as the key and the3.1 node-version:18 test-suite:spec:jestas the value.@Fryguy commented on GitHub (Jan 14, 2025):
Oh I think I finally got it:
I wasn't expecting to pass multiple single values, but it seems to work - I'm not sure how one would pass multiple inclusions this way.
@Fryguy commented on GitHub (Jan 14, 2025):
Closing this, but I might open a separate docs PR to clear up cases like this. Thanks for your help @Andy4495