Skip to content

Error while migrating with multiple github token #34141

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

Closed
VinothKumar-Ganesan opened this issue Apr 7, 2025 · 9 comments · Fixed by #34144
Closed

Error while migrating with multiple github token #34141

VinothKumar-Ganesan opened this issue Apr 7, 2025 · 9 comments · Fixed by #34144
Labels
issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail type/bug

Comments

@VinothKumar-Ganesan
Copy link

Description

Image

Gitea Version

1.23.6

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

docker

Database

None

wxiaoguang added a commit that referenced this issue Apr 13, 2025
Git authorization was not taking into account multiple token feature,
leading to auth failures

Closes: #34141

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
@VinothKumar-Ganesan
Copy link
Author

the entire GitHub migration was failing after this fix

@wxiaoguang wxiaoguang reopened this Apr 14, 2025
@wxiaoguang wxiaoguang added this to the 1.24.0 milestone Apr 14, 2025
@TheFox0x7
Copy link
Contributor

@VinothKumar-Ganesan
Please add more details. At the very least you should include version used to test, logs and error you got as well as steps to trigger the fault.

@wxiaoguang
Copy link
Contributor

@VinothKumar-Ganesan I also did a quick test, by using my personal access token github_pat_11AAQEF.........., it successfully cloned my private repo: https://github.com/wxiaoguang/test-private

Image


Image

@wxiaoguang wxiaoguang added the issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail label Apr 14, 2025
@wxiaoguang wxiaoguang removed this from the 1.24.0 milestone Apr 14, 2025
@VinothKumar-Ganesan
Copy link
Author

Hi @wxiaoguang , i am using the gitea/gitea:nightly image and after filling the page and select migrate repository

Image

it was navigating to the following page

Image

@wxiaoguang
Copy link
Contributor

wxiaoguang commented Apr 14, 2025

What's your "access token" (I mean: what kind it is and how it is created)? It looks much shorter than mine .....

@VinothKumar-Ganesan
Copy link
Author

i am using a single classical token also it was failing in multiple token too

Image

@wxiaoguang
Copy link
Contributor

OK, I can see there is no error.

Maybe you encountered another bug which should have been fixed by Fix bug when migrating repository #34182 (after fix github migration error when using multiple tokens #34144). Could you try to pull nightly and try again?

@VinothKumar-Ganesan
Copy link
Author

Hi @wxiaoguang , it was working fine now thanks for the support

@wxiaoguang
Copy link
Contributor

Glad to help. And special thanks to @TheFox0x7 for helping to investigate and fix the multiple token bug.

Thank you all, I think this issue could be closed.

DennisRasey pushed a commit to DennisRasey/forgejo that referenced this issue Apr 19, 2025
Git authorization was not taking into account multiple token feature,
leading to auth failures

Closes: go-gitea/gitea#34141

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
(cherry picked from commit 8a6df00c532becd4d10efb70827ccf80b2bf74e2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail type/bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants