mirror of
https://github.com/nektos/act.git
synced 2026-04-26 09:25:54 +03:00
[GH-ISSUE #2660] Is There a Summary of Job Results #1204
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#1204
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 @Betty1202 on GitHub (Feb 11, 2025).
Original GitHub issue: https://github.com/nektos/act/issues/2660
Act version
v0.2.74
Feature description
Hello,
I am currently using Act to execute GitHub Actions workflows locally and was wondering if there is a feature that provides a summary of the execution results for each job. Specifically, I'm looking for a way to output the results (e.g., success or failure) of all jobs into a JSON or TXT file.
Having a summary in a structured format would be very helpful for analyzing the workflow outcomes programmatically. Is there an existing feature or a recommended approach to achieve this in Act?
Thank you for your assistance!
@ChristopherHX commented on GitHub (Feb 11, 2025):
try option
--json, then try parse jsonl (json objects line by line, you should handle non json lines as well)Displaying logs and writing the json to file is not implemented
I'm not processing feature requests right now, due to being behind my roadmap of act
@Betty1202 commented on GitHub (Feb 12, 2025):
Got it. Thanks!
@ptagl commented on GitHub (Mar 12, 2025):
@ChristopherHX would you consider an external contribution for this feature?
It would be useful for me as well, so I tried something like this in the
runStepExecutor:It's more than enough for me as it prints something like:
@ChristopherHX commented on GitHub (Mar 15, 2025):
@ptagl I would suggest to add the duration as field for this as well e.g.
logger.WithFieldso json logs also have this precalculated value.I would consider myself as somewhat external as well, since I cannot decide on my own if your PR would be merged (here in nektos/act).
I'm perfectly fine with your logger enhancement, then my github-act-runner act log file has durations as well without needing to look at the webui of GitHub.
@ptagl commented on GitHub (Mar 17, 2025):
Do you mean something like this?
Standard log:
JSON log:
A small off-topic: I was trying to run tests with
make testbut I'm getting errors even onmasterwithout any changes (commit IDeb46e8aa5a23f99c76be4a53413a856d6b236145). The same happens if I try to runact --job test-linux.make-test.log
Any idea about what could be wrong here? I already followed the documentation and launched
docker run --privileged --rm tonistiigi/binfmt --install amd64,arm64.@ChristopherHX commented on GitHub (Mar 17, 2025):
yes
I only run selected failing tests locally, yes running the whole test suite is likely to fail on your system.
There seems to be problems when rerunning certain tests, not all of them are stateless.
If you have an ubuntu 22.04/24.04 x86_64 system + tonistiigi/binfmt for arm64 tests + a empty dockerd instance you can finish them exactly once without errors. For the second time you need to cleanup dockerd again.
you have an nested act checkout?, obviously this fails as it detects tests inside that folders that fail to compile
If you use multiple worktrees, place them outside of the src of act otherwise the
./...pattern would match them as well@ptagl commented on GitHub (Mar 18, 2025):
I've just opened the PR.
About the failing tests, I think I found the cause:
github.com/nektos/act/reportfolder was created, I needed to remove itdefaults-runtest fails because it expects to find more than one shell as the output ofecho $SHELL, but the medium Docker image I'm using only containsbashshells/pwshtest fails becausepwshis not available on the medium Docker imageBoth 2 and 3 are related to #1991.