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

Only the default branch 'refs/heads/null' is supported after #68 landed #73

Closed
ChrisCarini opened this issue Jan 28, 2022 · 6 comments · Fixed by #75
Closed

Only the default branch 'refs/heads/null' is supported after #68 landed #73

ChrisCarini opened this issue Jan 28, 2022 · 6 comments · Fixed by #75

Comments

@ChrisCarini
Copy link
Contributor

ChrisCarini commented Jan 28, 2022

Hello, I am getting the below error after #68 (fix for #66) landed and was picked up by my workflow:

Event file: /github/workflow/event.json
Event name: schedule
Ref: refs/heads/master
Private repository: null
Publication enabled: true
Format: sarif
Policy file: /policy.yml
Default branch: refs/heads/null
refs/heads/master not supported with 'schedule' event.
Only the default branch 'refs/heads/null' is supported

(ref: link)

This is happening on the scheduled runs of the workflow I have configured.

@laurentsimon - when you have a moment to take a look, could you help investigate? The repo in which this is run has the default branch set to master.

Thank you!

@laurentsimon
Copy link
Contributor

laurentsimon commented Jan 28, 2022

Thanks. I think I know what's happening. The schedule trigger does not seem to have a default branch, which is unexpected from me. I'll work on a fix.

cc @naveensrinivasan let's add better unit test for the action.

@laurentsimon
Copy link
Contributor

fyi, I've created a support ticket with GitHub.

@ChrisCarini
Copy link
Contributor Author

Awesome, thank you @laurentsimon !

@ChrisCarini
Copy link
Contributor Author

@laurentsimon - it's late for me, so perhaps I'm just missing something obvious because I am tired, but I just noticed this action failed again for me for the same reason: https://github.com/ChrisCarini/environment-variable-settings-summary-intellij-plugin/runs/5040554515?check_suite_focus=true

I have the action pinned to b614d455ee90608b5e36e3299cd50d457eb37d5f, which I believe is the commit after the fix here (which, I confirmed worked as expected when testing... 🤔 ).

Any ideas? This seems very strange to me, so perhaps I am missing something right now..

@laurentsimon
Copy link
Contributor

You're not missing anything, see #84. Looks like GITHUB_REPOSITORY is empty/not set on schedule triggers, which is unexpected. I'll update the #84 once we have a lead. Sorry about that.

@ChrisCarini
Copy link
Contributor Author

SGTM, and no worries! Appreciate you looking into this (and #84 😄 )!

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

Successfully merging a pull request may close this issue.

2 participants