-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
actions/checkout fails to retrieve default branch name #29654
Comments
It seems that GHES only have |
looks a quick fix option is seting - name: Checkout tools repo
uses: actions/checkout@v4
with:
repository: testa/test_1
path: my-tools
+ ref: main |
Yeah, that's what I ended up doing on the repo where I ran into this. |
Yeah, checkout will get default branch by using API, if you provided one, then there's no need to get it from API. |
#29676 is closely related and I think the best course of action is to implement this API shim for that one |
I closed #29676 in favor of this one. Basically we need to implement these APIs (the latter two likely already exist):
Relevant |
I think it's also called if neither ref nor commit are specified, even if git is present: https://github.com/actions/checkout/blob/8eb1f6a495037164bea451156472f35fdd6bafc0/src/git-source-provider.ts#L139 |
I am fairly new to gitea actions, but I am also running into this because (by design) didn't include git in my image. As long as the checkout action tries to download the archive from this non existing api endpoints i am forced to include git in my images or scrap gitea actions alltogether which would be sad |
Description
I have a private repo, with an actions workflow that uses
actions/checkout
(I've tried v3 and v4, both have this issue) to check out first itself, and then a different private repo, like this.When I run this, the action fails with this error:
Looking through the logs on the gitea side, I find:
Looking in the swagger ui, it looks like the base url is at
/api/v1
, so I assume that a v3 version of the route is just nonexistent.In the end, I was able to work around this issue by manually specifying a
ref: master
to check out in the action's config, and that let the rest of the checkout succeed.I'm having some trouble signing up on try.gitea.io at the moment, but I'll set up a repro on there when I get a chance.
Gitea Version
1.21.7
Can you reproduce the bug on the Gitea demo site?
No
Log Gist
No response
Screenshots
No response
Git Version
2.43.1
Operating System
linux (nixos unstable)
How are you running Gitea?
gitea via nixos's package (runs under systemd, no containers), behind a nginx reverse proxy.
gitea instance is under its own subdomain, no extra subdir that it lives under.
the actions runner is also installed via nixos's package manager, running under systemd, on the same box
Database
PostgreSQL
The text was updated successfully, but these errors were encountered: