-
Notifications
You must be signed in to change notification settings - Fork 25
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
Error: Bad credentials - using v5
on self-hosted runner
#221
Comments
When self-hosted, it seems like "github-token" must be setted. - uses: astral-sh/setup-uv@v5
with:
enable-cache: true
prune-cache: false
github-token: ${{ secrets.MY_GITHUB_TOKEN }} |
Hmm interesting I wonder why For reference, I'm using |
I'm using Gitea too, you're not forced to put token secret in every repo, you can scope the secret for each organization account of your gitea instance, so the token will be automatically available into all repo of related organization. |
@adr1enbe4udou1n Thanks for that tip. I still hope there can be a way to use As a point of comparison that I hope is relevant, the
|
Thank you for creating the detailed issues you have with Gitea. I currently do not see why v3 works but v4 doesn't. There might however be a workaround I could implement to work with an empty Github token. Please be aware that I only a limited amount of time I can work on this. I am happy to review PRs! |
This action currently assumes that it is running in the GitHub ecosystem which makes sure that the env var GITHUB_TOKEN is always set and can be used to connect to the Github REST API. If you are using e.g. Gitea please make sure that you provide a valid token. To solve that we need to exchange octokit with other means to collect release information which does not need a token. |
I am also hitting this with self-hosted GHE.
While not the most straight forward, I could see a basic "if you don't provide a valid token, you must explicitly set the version you want to dl" policy. This might be too much of a hack, but I use this trick in bash scripts from time to time: ❯ wget -q -O - https://api.github.com/repos/astral-sh/uv/releases/latest | jq -r '.assets[] | .browser_download_url'
https://github.com/astral-sh/uv/releases/download/0.5.20/dist-manifest.json
https://github.com/astral-sh/uv/releases/download/0.5.20/sha256.sum
https://github.com/astral-sh/uv/releases/download/0.5.20/source.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/source.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-aarch64-apple-darwin.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-aarch64-apple-darwin.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-aarch64-unknown-linux-gnu.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-aarch64-unknown-linux-gnu.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-aarch64-unknown-linux-musl.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-aarch64-unknown-linux-musl.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-arm-unknown-linux-musleabihf.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-arm-unknown-linux-musleabihf.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-armv7-unknown-linux-gnueabihf.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-armv7-unknown-linux-gnueabihf.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-armv7-unknown-linux-musleabihf.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-armv7-unknown-linux-musleabihf.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-i686-pc-windows-msvc.zip
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-i686-pc-windows-msvc.zip.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-i686-unknown-linux-gnu.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-i686-unknown-linux-gnu.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-i686-unknown-linux-musl.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-i686-unknown-linux-musl.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-installer.ps1
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-installer.sh
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-powerpc64-unknown-linux-gnu.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-powerpc64-unknown-linux-gnu.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-powerpc64le-unknown-linux-gnu.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-powerpc64le-unknown-linux-gnu.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-s390x-unknown-linux-gnu.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-s390x-unknown-linux-gnu.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-apple-darwin.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-apple-darwin.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-pc-windows-msvc.zip
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-pc-windows-msvc.zip.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-unknown-linux-gnu.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-unknown-linux-gnu.tar.gz.sha256
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-unknown-linux-musl.tar.gz
https://github.com/astral-sh/uv/releases/download/0.5.20/uv-x86_64-unknown-linux-musl.tar.gz.sha256 Add one more |
This is a new issue for
v5
, but it is also a follow on from the issue I faced withv4
- see #192. Going fromv3
tov4
was giving me a::error::GetUserByName: "user redirect does not exist [name: astral-sh]"
error, which is still unsolved.Today I tried migrating from
v3
tov5
.But now I'm getting a
::error::Bad credentials - https://docs.github.com/rest
error.As with issue #192, if I downgrade to
v3
everything works.Logs
The text was updated successfully, but these errors were encountered: