Problem with adopting unadopted Repositories #13286

Closed
opened 2025-11-02 10:37:27 -06:00 by GiteaMirror · 7 comments
Owner

Originally created by @muhamad on GitHub (Jul 14, 2024).

Description

Steps to reproduce it as it happened with me:

  1. Create an organization with normal name like online.
  2. In the filesystem go to repos directory and create directory with name online.
  3. Put not less than 60 bare repository in that directory (I've 280 bar repo which are later be mirrored).
  4. In Gitea go to Site Administration ->Code Assets -> Repositories then click on Unadopted Repositories.
  5. In the search box write online then press search icon.
  6. In the list of repositories start adopting them by pressing Adopt Files.
  7. when you reach the 15th repository the adopted repositories from 1st to 14th will start getting listed again one by one when continuing adopting other repositories.

Gitea Version

1.22.1

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

No response

Git Version

git version 2.45.0.windows.1

Operating System

Windows 10 Pro 22H2

How are you running Gitea?

As a windows service, but issue can be produced running as standalone application

Database

SQLite

Originally created by @muhamad on GitHub (Jul 14, 2024). ### Description Steps to reproduce it as it happened with me: 1. Create an organization with normal name like `online`. 2. In the filesystem go to repos directory and create directory with name `online`. 3. Put not less than 60 bare repository in that directory (I've 280 bar repo which are later be mirrored). 4. In Gitea go to `Site Administration` ->`Code Assets` -> `Repositories` then click on `Unadopted Repositories`. 5. In the search box write `online` then press search icon. 6. In the list of repositories start adopting them by pressing `Adopt Files`. 7. when you reach the 15th repository the adopted repositories from 1st to 14th will start getting listed again one by one when continuing adopting other repositories. ### Gitea Version 1.22.1 ### Can you reproduce the bug on the Gitea demo site? No ### Log Gist _No response_ ### Screenshots _No response_ ### Git Version git version 2.45.0.windows.1 ### Operating System Windows 10 Pro 22H2 ### How are you running Gitea? As a windows service, but issue can be produced running as standalone application ### Database SQLite
GiteaMirror added the type/bug label 2025-11-02 10:37:27 -06:00
Author
Owner

@muhamad commented on GitHub (Aug 4, 2024):

Up to not get forgotten.

@muhamad commented on GitHub (Aug 4, 2024): Up to not get forgotten.
Author
Owner

@Zettat123 commented on GitHub (Sep 25, 2024):

I cannot reproduce this issue. Are there any errors in the logs when adopting repos?

@Zettat123 commented on GitHub (Sep 25, 2024): I cannot reproduce this issue. Are there any errors in the logs when adopting repos?
Author
Owner

@muhamad commented on GitHub (Sep 25, 2024):

No there is not, Also I was able to reproduce it again in gitea 1.22.2 using the executable "gitea-1.22.2-windows-4.0-amd64.exe".

To reproduce it do the following

  1. Start gitea without database then create a user "X" and an organization "Y".
  2. In the data folder for repos create a folder with name "Y".
  3. In the folder Y run the powershell command 1..60 | % tostring 00 | % { git init --bare ".\$_.git" } to create 60 bare repos in the format xx.git
  4. Start adopting the bare repos in Y. when adopt all to the 50 - including it - everything still fine.
  5. Once you adopt the repo 51 the repo 01 will re-apear in the Unadopted Repositories section again.
  6. If you continue adopting repos the section Unadopted Repositories will keep showing adopted repos, I guess to keep the 50 entry per page.
@muhamad commented on GitHub (Sep 25, 2024): No there is not, Also I was able to reproduce it again in gitea 1.22.2 using the executable "gitea-1.22.2-windows-4.0-amd64.exe". To reproduce it do the following 1. Start gitea without database then create a user "X" and an organization "Y". 2. In the data folder for repos create a folder with name "Y". 3. In the folder `Y` run the powershell command `1..60 | % tostring 00 | % { git init --bare ".\$_.git" }` to create 60 bare repos in the format `xx.git` 4. Start adopting the bare repos in `Y`. when adopt all to the `50` - including it - everything still fine. 5. Once you adopt the repo `51` the repo `01` will re-apear in the `Unadopted Repositories` section again. 6. If you continue adopting repos the section `Unadopted Repositories` will keep showing adopted repos, I guess to keep the 50 entry per page.
Author
Owner

@muhamad commented on GitHub (Dec 4, 2024):

??

@muhamad commented on GitHub (Dec 4, 2024): ??
Author
Owner

@wxiaoguang commented on GitHub (Dec 5, 2024):

There are different "adopt" pages.

I think the problem you encountered is the admin page. But to be honest, I have no idea how to reproduce.

I managed to created 90 repositories:

for i in {10..99}; do git init --bare "$i.git"; done

Then I could adopt beyond 60:

image

@wxiaoguang commented on GitHub (Dec 5, 2024): There are different "adopt" pages. I think the problem you encountered is the admin page. But to be honest, I have no idea how to reproduce. I managed to created 90 repositories: ``` for i in {10..99}; do git init --bare "$i.git"; done ``` Then I could adopt beyond 60: ![image](https://github.com/user-attachments/assets/0ad38de1-3209-46a2-91f1-fdcdb9fdb59b)
Author
Owner

@muhamad commented on GitHub (Dec 6, 2024):

Your're correct, I use the Adopt repositories from the admin page. I didn't migrate to latest gitea release, I will check and get back to you.

-- Edit

After migrating to the latest version (1.22.4) this bug is no longer exist.

Thank you for awesome application.

@muhamad commented on GitHub (Dec 6, 2024): Your're correct, I use the Adopt repositories from the admin page. I didn't migrate to latest gitea release, I will check and get back to you. -- Edit After migrating to the latest version (1.22.4) this bug is no longer exist. Thank you for awesome application.
Author
Owner

@wxiaoguang commented on GitHub (Dec 6, 2024):

Thank you for the quick feedkback. I think this issue could be closed.

@wxiaoguang commented on GitHub (Dec 6, 2024): Thank you for the quick feedkback. I think this issue could be closed.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#13286