"404 failed to parse unknown error format" when migrating from private gitlab to gitea #9699

Open
opened 2025-11-02 08:46:57 -06:00 by GiteaMirror · 8 comments
Owner

Originally created by @martijnschouten on GitHub (Oct 17, 2022).

Description

I'm trying to migrate a private git from the GitLab server from work. I made a personal access token, copied the https link from the repository and filled both in into the migration page. When I click migrate repository I get:

Migrating from https://git.ram.eemcs.utwente.nl/schoutenm/analyse-mfeit.git failed.

When I look in the logs of my app I see:

...ervices/task/task.go:56:handle() [E] Run task failed: GET https://git.ram.eemcs.utwente.nl/api/v4/projects/schoutenm/analyse-mfeit: 404 failed to parse unknown error format

If I migrate a private git from github with an access code everything goes fine.

Gitea Version

1.17.2_9.0.22

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

https://github.com/go-gitea/gitea/files/9804253/gitea_gitea-56745bbc6b-pzxjp_gitea.1.zip

Screenshots

No response

Git Version

not sure

Operating System

truenas scale (debian+docker)

How are you running Gitea?

I installed Gitea on Truenas Scale from the TrueCharts catalog. For the time being I'm running the server behind a nat (access it using a internal IP address and port number). I added this IP address and port number as a custom configuration parameter as server.root_url

Database

No response

Originally created by @martijnschouten on GitHub (Oct 17, 2022). ### Description I'm trying to migrate a private git from the GitLab server from work. I made a personal access token, copied the https link from the repository and filled both in into the migration page. When I click migrate repository I get: >Migrating from https://git.ram.eemcs.utwente.nl/schoutenm/analyse-mfeit.git failed. When I look in the logs of my app I see: > ...ervices/task/task.go:56:handle() [E] Run task failed: GET https://git.ram.eemcs.utwente.nl/api/v4/projects/schoutenm/analyse-mfeit: 404 failed to parse unknown error format If I migrate a private git from github with an access code everything goes fine. ### Gitea Version 1.17.2_9.0.22 ### Can you reproduce the bug on the Gitea demo site? Yes ### Log Gist https://github.com/go-gitea/gitea/files/9804253/gitea_gitea-56745bbc6b-pzxjp_gitea.1.zip ### Screenshots _No response_ ### Git Version not sure ### Operating System truenas scale (debian+docker) ### How are you running Gitea? I installed Gitea on Truenas Scale from the TrueCharts catalog. For the time being I'm running the server behind a nat (access it using a internal IP address and port number). I added this IP address and port number as a custom configuration parameter as server.root_url ### Database _No response_
GiteaMirror added the type/bug label 2025-11-02 08:46:57 -06:00
Author
Owner

@techknowlogick commented on GitHub (Oct 17, 2022):

Which version of Gitlab is your remote using?

@techknowlogick commented on GitHub (Oct 17, 2022): Which version of Gitlab is your remote using?
Author
Owner

@martijnschouten commented on GitHub (Oct 17, 2022):

It is using GitLab Enterprise Edition 15.4.2-ee

@martijnschouten commented on GitHub (Oct 17, 2022): It is using GitLab Enterprise Edition 15.4.2-ee
Author
Owner

@martijnschouten commented on GitHub (Oct 17, 2022):

I now clicked on git instead of gitlab in the migrate options. If I then fill in the https link, my account name and my access code it does work.

@martijnschouten commented on GitHub (Oct 17, 2022): I now clicked on git instead of gitlab in the migrate options. If I then fill in the https link, my account name and my access code it does work.
Author
Owner

@techknowlogick commented on GitHub (Oct 17, 2022):

Thanks for those details and update <3

I'll suggest this is left open in case Gitlab 15 changes anything with their API in terms of us importing.

@techknowlogick commented on GitHub (Oct 17, 2022): Thanks for those details and update <3 I'll suggest this is left open in case Gitlab 15 changes anything with their API in terms of us importing.
Author
Owner

@x45dev commented on GitHub (Nov 2, 2023):

Same problem for Gitlab 16.2+

@x45dev commented on GitHub (Nov 2, 2023): Same problem for Gitlab 16.2+
Author
Owner

@zadjadr commented on GitHub (Jul 26, 2024):

Using the read_api (instead of read_repository) fixed it for me on 17.2

@zadjadr commented on GitHub (Jul 26, 2024): Using the `read_api` (instead of `read_repository`) fixed it for me on 17.2
Author
Owner

@lunny commented on GitHub (Aug 5, 2024):

Using the read_api (instead of read_repository) fixed it for me on 17.2

How did you change to read_api?

@lunny commented on GitHub (Aug 5, 2024): > Using the `read_api` (instead of `read_repository`) fixed it for me on 17.2 How did you change to `read_api`?
Author
Owner

@zadjadr commented on GitHub (Aug 6, 2024):

Using the read_api (instead of read_repository) fixed it for me on 17.2

How did you change to read_api?

During gitlab token creation, you need to choose the read_api scope:

https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html#personal-access-token-scopes

@zadjadr commented on GitHub (Aug 6, 2024): > > Using the `read_api` (instead of `read_repository`) fixed it for me on 17.2 > > How did you change to `read_api`? During gitlab token creation, you need to choose the read_api scope: https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html#personal-access-token-scopes
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#9699