Skip to content
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

Switch to interface{} instead of map[string]... #700

Merged
merged 4 commits into from
Jun 6, 2021

Conversation

catthehacker
Copy link
Member

@catthehacker catthehacker commented May 23, 2021

Fixes issue with env: keys not being able to accept GitHub functions like fromJSON()
Fixes issue with matrixes not being able to be built with GitHub functions like fromJSON()

Fixed issues:
fixes #284
fixes #540
fixes #450
fixes #330

@codecov
Copy link

codecov bot commented May 23, 2021

Codecov Report

Merging #700 (3dab0bf) into master (0f04942) will increase coverage by 0.61%.
The diff coverage is 53.40%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #700      +/-   ##
==========================================
+ Coverage   49.27%   49.88%   +0.61%     
==========================================
  Files          23       23              
  Lines        2401     2568     +167     
==========================================
+ Hits         1183     1281      +98     
- Misses       1090     1146      +56     
- Partials      128      141      +13     
Impacted Files Coverage Δ
pkg/container/docker_run.go 1.84% <0.00%> (-0.09%) ⬇️
pkg/model/workflow.go 25.29% <2.43%> (-0.43%) ⬇️
pkg/common/git.go 53.08% <30.15%> (-6.72%) ⬇️
pkg/model/planner.go 34.56% <41.37%> (+1.48%) ⬆️
pkg/container/docker_pull.go 36.17% <64.70%> (+17.98%) ⬆️
pkg/runner/step_context.go 72.05% <71.85%> (+3.11%) ⬆️
pkg/runner/run_context.go 79.84% <95.38%> (+3.44%) ⬆️
pkg/runner/command.go 90.58% <100.00%> (+2.35%) ⬆️
pkg/runner/runner.go 76.92% <100.00%> (+0.45%) ⬆️
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fa93f4d...3dab0bf. Read the comment docs.

@catthehacker
Copy link
Member Author

I'm actually surprised this works

hackercat added 2 commits May 23, 2021 01:34
allows to use GitHub functions like `fromJson()`
This allows to use GitHub functions like `fromJson()` to create dynamic
matrixes
@pull-request-size pull-request-size bot added size/M and removed size/L labels May 23, 2021
@catthehacker catthehacker marked this pull request as ready for review May 23, 2021 01:41
@catthehacker catthehacker requested a review from a team as a code owner May 23, 2021 01:41
@catthehacker catthehacker changed the title fix: properly understand matrix if it's set dynamically Switch to interface{} instead of map[string]... May 23, 2021
@mergify

This comment has been minimized.

@mergify mergify bot added the needs-work Extra attention is needed label May 24, 2021
@catthehacker

This comment has been minimized.

@mergify mergify bot removed the needs-work Extra attention is needed label Jun 6, 2021
@mergify mergify bot merged commit 33ccfa6 into nektos:master Jun 6, 2021
@pawelmhm

This comment has been minimized.

@catthehacker

This comment has been minimized.

@catthehacker
Copy link
Member Author

Checked checks.yml and tests-ubuntu.yml, both work fine on act@master

@pawelmhm

This comment has been minimized.

@catthehacker

This comment has been minimized.

@pawelmhm

This comment has been minimized.

@pawelmhm
Copy link

pawelmhm commented Jun 8, 2021

ah right that may be some old act version, let me double chck sorry, I though go install will override other install, but maybe it didnt

@catthehacker
Copy link
Member Author

It should, but maybe it sometimes doesn't do that. I've been using go install github.com/nektos/act@master and from source and never had that issue tbh

@pawelmhm
Copy link

pawelmhm commented Jun 8, 2021

I installed it properly, master version works fine, no yaml error. Thanks for this useful tool!

@sarah-liang
Copy link

sarah-liang commented Jun 10, 2021

currently getting unmarshal errors while running act for the first time in my repo:

Error: yaml: unmarshal errors:
line 49: cannot unmarshal !!str '${{ fro...' into map[string]string
line 73: cannot unmarshal !!str '${{ fro...' into map[string]string
line 116: cannot unmarshal !!str '${{ fro..' into map[string]string
line 157: cannot unmarshal !!str '${{ fro...' into map[string]string

is this a me problem or something not addressed in this fix? Im using v0.2.22

@catthehacker
Copy link
Member Author

@sarah-liang this fix is not included in v0.2.22

@aurimasniekis

This comment has been minimized.

@catthehacker
Copy link
Member Author

@aurimasniekis please create new issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
5 participants