Description
After upgrading Gitea from 1.25.x to 1.26.x, the repo-archive unique queue can contain jobs serialized with the old ArchiveRequest JSON shape. Workers on 1.26 fail to unmarshal those items and log errors like:
.../queue/workerqueue.go:155:(*WorkerPoolQueue).unmarshal() [E] Failed to unmarshal item from queue "repo-archive":
json: unable to unmarshal into Go convert.Conversion within "/Repo/Units/0/Config":
cannot derive concrete type for nil interface with finite type set
Root cause
ArchiveRequest changed between releases (see #35514 / subpath archive work in 1.26):
v1.25 (services/repository/archiver/archiver.go):
type ArchiveRequest struct {
RepoID int64
Type git.ArchiveType
CommitID string
archiveRefShortName string
}
v1.26+:
type ArchiveRequest struct {
Repo *repo_model.Repository // includes Units[].Config (interface types)
Type repo_model.ArchiveType
CommitID string
Paths []string
archiveRefShortName string
}
The repo-archive queue persists JSON via WorkerPoolQueue. Jobs enqueued under 1.25 are not compatible with the 1.26 struct, especially Repo.Units[0].Config where convert.Conversion cannot be derived from stored JSON.
Impact
- Queue workers repeatedly log unmarshal errors for stale items.
- With
STREAM_ARCHIVES=false, full-repo archive API requests can hang in Await() if the unique set still thinks a job exists but nothing processes successfully.
- Workaround: Site Administration → Monitor → Queues →
repo-archive → Remove all items (and optionally clear stuck repo_archiver rows with status = 0).
Steps to reproduce
- Run Gitea 1.25.x with
STREAM_ARCHIVES=false (or otherwise enqueue full-repo archive jobs into repo-archive).
- Trigger at least one full-repo archive download so jobs sit in the persistent queue (level/redis).
- Upgrade to 1.26.x without flushing/clearing the
repo-archive queue.
- Observe unmarshal errors in logs; full-repo archive HTTP requests may hang.
Expected behavior
One of:
- Queue is automatically invalidated / migrated on upgrade when
ArchiveRequest schema changes.
- Upgrade docs explicitly instruct clearing
repo-archive before/after upgrade.
- Queue payload stores a version-stable minimal struct (e.g.
RepoID + CommitID + Paths) instead of full *Repository.
Actual behavior
Stale 1.25 queue payloads break 1.26 workers; errors repeat until an admin manually clears the queue.
Gitea Version
Observed on 1.26.2 after upgrade from 1.25.x. Still present in 1.26.4 (archiver.go unchanged). Not fixed on main as of June 2026.
Environment
- Queue: default persistent unique queue (
repo-archive)
STREAM_ARCHIVES=false forces queued full-repo archives (subpath ?path=... streams on 1.26 and bypasses the queue)
Related issues
These do not document the 1.25 → 1.26 ArchiveRequest breaking schema change specifically.
Suggested fix
- On startup after upgrade, detect incompatible
repo-archive items and drop them (or reset the queue), or
- Revert queue payload to a minimal serializable struct and load
Repository in the worker handler.
Description
After upgrading Gitea from 1.25.x to 1.26.x, the
repo-archiveunique queue can contain jobs serialized with the oldArchiveRequestJSON shape. Workers on 1.26 fail to unmarshal those items and log errors like:Root cause
ArchiveRequestchanged between releases (see #35514 / subpath archive work in 1.26):v1.25 (
services/repository/archiver/archiver.go):v1.26+:
The
repo-archivequeue persists JSON viaWorkerPoolQueue. Jobs enqueued under 1.25 are not compatible with the 1.26 struct, especiallyRepo.Units[0].Configwhereconvert.Conversioncannot be derived from stored JSON.Impact
STREAM_ARCHIVES=false, full-repo archive API requests can hang inAwait()if the unique set still thinks a job exists but nothing processes successfully.repo-archive→ Remove all items (and optionally clear stuckrepo_archiverrows withstatus = 0).Steps to reproduce
STREAM_ARCHIVES=false(or otherwise enqueue full-repo archive jobs intorepo-archive).repo-archivequeue.Expected behavior
One of:
ArchiveRequestschema changes.repo-archivebefore/after upgrade.RepoID+CommitID+Paths) instead of full*Repository.Actual behavior
Stale 1.25 queue payloads break 1.26 workers; errors repeat until an admin manually clears the queue.
Gitea Version
Observed on 1.26.2 after upgrade from 1.25.x. Still present in 1.26.4 (
archiver.gounchanged). Not fixed onmainas of June 2026.Environment
repo-archive)STREAM_ARCHIVES=falseforces queued full-repo archives (subpath?path=...streams on 1.26 and bypasses the queue)Related issues
repo-archivequeue — workaround: clear queue)These do not document the 1.25 → 1.26
ArchiveRequestbreaking schema change specifically.Suggested fix
repo-archiveitems and drop them (or reset the queue), orRepositoryin the worker handler.