Kyle Isom 61b8c2fcef Fix manifest push 500: use explicit SELECT instead of LastInsertId
SQLite's last_insert_rowid() only updates on actual INSERTs, not
ON CONFLICT DO UPDATE. When pushing a second tag for an existing
manifest digest, the upsert fires the conflict branch (no new row),
so LastInsertId() returns a stale ID from a previous insert. This
caused manifest_blobs and tags to reference the wrong manifest,
producing a 500 on the PUT manifest response.

Replace LastInsertId() with a SELECT id WHERE repository_id AND
digest query within the same transaction.

Security: manifest_blobs and tag foreign keys now always reference
the correct manifest.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 12:35:39 -07:00
2026-03-25 21:01:28 -07:00
2026-03-25 21:01:28 -07:00

MCR is the Metacircular Container Registry

This is a container registry integrated with MCIAS.

Description
No description provided
Readme 42 MiB
Languages
Go 95.4%
HTML 2.5%
CSS 1.3%
Shell 0.5%
Makefile 0.2%
Other 0.1%