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

Coverage report CI should not use gwion-action #184

Closed
fennecdjay opened this issue Oct 2, 2020 · 12 comments
Closed

Coverage report CI should not use gwion-action #184

fennecdjay opened this issue Oct 2, 2020 · 12 comments

Comments

@fennecdjay
Copy link
Member

Rather simply build it like in the other actions, setting USE_COVERAGE as an environment variable.

@TotallyNotChase
Copy link
Contributor

Should this step be replaced with a regular checkout@v2 action followed by a

- run: |
        git submodule update --init util ast
        make

And also followed by a

env:
        USE_COVERAGE: 1

?

@fennecdjay
Copy link
Member Author

Yes. You'll also need make test or coverage report will be 0%.

@TotallyNotChase
Copy link
Contributor

I think this issue would be present in the all the workflows that use gwion-action. Although most of the other ones only run on push, not PR. Do you think fixing this from the gwion-action side itself can make this more streamlined?

@fennecdjay
Copy link
Member Author

You're right. But I think gwion-action made its time. I started using (linux) releases for other CI, repl.it or anyfiddle. I'm more looking forward a action-make thingy, which could be more general. For this particular issue, I think good old checkout@v2 + make test is the way to go.

@TotallyNotChase
Copy link
Contributor

Alright. There seems to be another issue though. On PRs, github.event.ref seems to be a blank string. Any idea what this could be caused by?

Action results for context. branch=$(basename ${{ github.event.ref }}) evaluated to branch=$(basename )

@fennecdjay
Copy link
Member Author

I didn't see that coming!
From here: I think we must check existence of '${{ github.event.ref }}' (which is also $GITHUB_REF, and if it does not exists, use ${{ github.event.base_ref }} or ${{ github.event.head_ref }}. I'm not sure which, I'd guess GITHUB_HEAD_REF`. Just my two cents actually, but I hope this helps.
Thanks for your efforts!

@TotallyNotChase
Copy link
Contributor

hmmm looks like neither github.event.base_ref nor github.event.head_ref exists on PR

@fennecdjay
Copy link
Member Author

That's a shame. did you try with $GITHUB_HEAD_REF?

@fennecdjay
Copy link
Member Author

Maybe this stack overflow page is relevant.

@TotallyNotChase
Copy link
Contributor

ok it looks like github.ref is great for pushes and github.event.head.ref is the one for PRs, I'll check those.

I think there may be another issue in the send mail bit though. Will get back to you on that

@fennecdjay
Copy link
Member Author

Please do. I really appreciate!

@fennecdjay
Copy link
Member Author

fennecdjay commented Oct 4, 2020

Lookin at this build and its workflow, I think the problem you have with the mailing is that you migh not have set MAIL_USERNAME and MAIL_USERPASSWORD in your repository secrets.


EDIT: About this mail thing, I might be the only one who wants his mail spammed by gwion coverage reports 😄. Probably best to not run this step if one of those variables is not set. But that's another issue. (so I just created #193).

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

No branches or pull requests

2 participants