When using gitea-mirror, it is possible to configure a maximum number of releases to be synced and retained per repository.
However, the expected cleanup behavior does not appear to be working correctly.
Expected behavior
If this limit is configured for release synchronization, then for each repository it should be ensured that the number of synced releases does not exceed the configured maximum. When a new release is synchronized and the limit is already reached, the oldest release in that repository should be automatically removed so that the limit is consistently enforced.
Actual behavior
At least for my instance the configured release retention limit is not consistently enforced. Even though a global limit (in my case 5) is set, repositories often exceed this limit after multiple sync runs. In some cases, repositories contain 7–10 releases instead of the configured maximum. There is no visible error during synchronization, and releases continue to be added without triggering cleanup. Additionally, there is currently no option to manually trigger the cleanup process for releases, which makes it difficult to correct already inconsistent states or to align enforcement of the retention policy.
**Description**
When using gitea-mirror, it is possible to configure a maximum number of releases to be synced and retained per repository.
However, the expected cleanup behavior does not appear to be working correctly.
**Expected behavior**
If this limit is configured for release synchronization, then for each repository it should be ensured that the number of synced releases does not exceed the configured maximum. When a new release is synchronized and the limit is already reached, the oldest release in that repository should be automatically removed so that the limit is consistently enforced.
**Actual behavior**
At least for my instance the configured release retention limit is not consistently enforced. Even though a global limit (in my case 5) is set, repositories often exceed this limit after multiple sync runs. In some cases, repositories contain 7–10 releases instead of the configured maximum. There is no visible error during synchronization, and releases continue to be added without triggering cleanup. Additionally, there is currently no option to manually trigger the cleanup process for releases, which makes it difficult to correct already inconsistent states or to align enforcement of the retention policy.
<!-- github-sync-id:4245682035 -->
Hey! This should be fixed in #266. Two things were broken:
Release updates were using PUT instead of PATCH, causing silent HTTP 405 errors on every sync
The releaseLimit config only limited how many releases were fetched from GitHub — it never actually cleaned up excess releases on the Gitea side
Both are fixed now. After syncing, the oldest releases beyond your configured limit will be automatically removed.
You can test with the PR image: ghcr.io/raylabshq/gitea-mirror:pr-266
Hey! This should be fixed in #266. Two things were broken:
1. Release updates were using `PUT` instead of `PATCH`, causing silent HTTP 405 errors on every sync
2. The `releaseLimit` config only limited how many releases were fetched from GitHub — it never actually cleaned up excess releases on the Gitea side
Both are fixed now. After syncing, the oldest releases beyond your configured limit will be automatically removed.
You can test with the PR image: `ghcr.io/raylabshq/gitea-mirror:pr-266`
<!-- github-comment-id:4233881067 -->
Hi, thanks for taking the time to fix this issue. I will test it as ssons as the next stable release is available. :)
Hi, thanks for taking the time to fix this issue. I will test it as ssons as the next stable release is available. :)
<!-- github-comment-id:4251965492 -->
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Description
When using gitea-mirror, it is possible to configure a maximum number of releases to be synced and retained per repository.
However, the expected cleanup behavior does not appear to be working correctly.
Expected behavior
If this limit is configured for release synchronization, then for each repository it should be ensured that the number of synced releases does not exceed the configured maximum. When a new release is synchronized and the limit is already reached, the oldest release in that repository should be automatically removed so that the limit is consistently enforced.
Actual behavior
At least for my instance the configured release retention limit is not consistently enforced. Even though a global limit (in my case 5) is set, repositories often exceed this limit after multiple sync runs. In some cases, repositories contain 7–10 releases instead of the configured maximum. There is no visible error during synchronization, and releases continue to be added without triggering cleanup. Additionally, there is currently no option to manually trigger the cleanup process for releases, which makes it difficult to correct already inconsistent states or to align enforcement of the retention policy.
Hey! This should be fixed in #266. Two things were broken:
PUTinstead ofPATCH, causing silent HTTP 405 errors on every syncreleaseLimitconfig only limited how many releases were fetched from GitHub — it never actually cleaned up excess releases on the Gitea sideBoth are fixed now. After syncing, the oldest releases beyond your configured limit will be automatically removed.
You can test with the PR image:
ghcr.io/raylabshq/gitea-mirror:pr-266Hi, thanks for taking the time to fix this issue. I will test it as ssons as the next stable release is available. :)