feat: found copies foundation (contracts, migration 0012, store, wire, trash and job hooks, keys)

Owner review 6 asks Chronos to recognise the same time-lapse held under different ids on the
server and on this PC, compare the copies, and keep them apart or integrate and sync them. This
lays the shared foundation the later parcels build on, without any UI or detection yet.

- Migration 0012 adds found_copies (local-server and local-local pairs with evidence, scores,
  answer, policy and the 404 record) and copy_probes; every existing link with a local sequence
  becomes a Linked pair, so a server deletion and the per-link policy have a place.
- FoundCopyStore keeps the pairs: upserts that never touch the answer, a compare-and-set of the
  state with an Integrating backstop (a failed or cancelled job reads as the previous state),
  link promotion and demotion, the once-per-refresh 404 count, the merge's links stage
  (session keys, links reset, pairs moved, refused when both are linked on one server), the
  local overlap queries and the probes. SyncLinkStore.RekeyAsync moves pairs and probes with
  the links in the same transaction.
- Contracts for detection, review, plans, the Integrate and MergeSequences jobs (kinds 25/26,
  High level, new detail steps) and the Upload all rule that keeps suspected, kept-apart,
  deleted, busy and server-born sequences here.
- Wire: POST photos/lookup, uploads into a target (IntoTarget/Copied, trailing and optional),
  frames/delete on the client, capabilities photo-lookup and upload-into, cached per remote.
- The trash plans and deletes accept the job that holds the sequence (its own hold is not
  Busy) and a frames version checked under the lease; a Background job never interrupts a
  running one.
- Settings for linking, the photo policy and projects; the en and it keys of design section 9.

Refs #73

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Alby96andClaude Opus 5.5 committed 2026-11-16 19:39:04 +01:00
1 parent 43719bb5c5
commit 283d04d9cd
57 files changed
+3302 -26

No files matched your search

+28
View File
@@ -133,4 +133,32 @@
<data name="Errors.Videos.TrashMismatch" xml:space="preserve"><value>Il video nel cestino non corrisponde più al suo registro; resta nel cestino.</value></data>
<data name="Errors.Videos.Busy" xml:space="preserve"><value>Un'attività sta usando {0}; riprova quando finisce.</value></data>
<data name="Errors.Videos.CannotPlay" xml:space="preserve"><value>Windows non sa decodificare questo file qui; Mostra nella cartella apre la sua cartella.</value></data>
<data name="Errors.Copies.StalePlan" xml:space="preserve"><value>Le sequenze sono cambiate dopo il piano: confrontale di nuovo.</value></data>
<data name="Errors.Copies.LinkTaken" xml:space="preserve"><value>{0} è già collegata a un'altra sequenza di {1}.</value></data>
<data name="Errors.Copies.DetailsChanged" xml:space="preserve"><value>I dettagli sono cambiati su un lato nel frattempo; le foto sono al loro posto, confronta di nuovo.</value></data>
<data name="Errors.Copies.Changed" xml:space="preserve"><value>{0} è cambiata durante l'unione; nulla è andato nel cestino.</value></data>
<data name="Errors.Copies.ChangedFile" xml:space="preserve"><value>{0} non corrisponde più al suo hash; nulla è andato nel cestino. Esegui Verifica.</value></data>
<data name="Errors.Copies.RemoteGone" xml:space="preserve"><value>Il server ha eliminato la sua sequenza nel frattempo; non è stato inviato altro.</value></data>
<data name="Errors.Copies.VerifyFailed.one" xml:space="preserve"><value>{0} foto non corrisponde dopo la copia: nulla è andato nel cestino.</value></data>
<data name="Errors.Copies.VerifyFailed.other" xml:space="preserve"><value>{0} foto non corrispondono dopo la copia: nulla è andato nel cestino.</value></data>
<data name="Errors.Copies.Kept.one" xml:space="preserve"><value>{0} foto è rimasta com'era; il registro del lavoro dice perché.</value></data>
<data name="Errors.Copies.Kept.other" xml:space="preserve"><value>{0} foto sono rimaste com'erano; il registro del lavoro dice perché.</value></data>
<data name="Errors.Copies.ProjectsKept.one" xml:space="preserve"><value>{0} progetto non è stato copiato; il registro dice perché.</value></data>
<data name="Errors.Copies.ProjectsKept.other" xml:space="preserve"><value>{0} progetti non sono stati copiati; il registro dice perché.</value></data>
<data name="Errors.Copies.NoSpace" xml:space="preserve"><value>{0} ha bisogno di {1} liberi; libera spazio e riprova.</value></data>
<data name="Errors.Copies.Busy" xml:space="preserve"><value>Un lavoro sta usando una di queste sequenze; riprova quando finisce.</value></data>
<data name="Errors.Copies.Unsent" xml:space="preserve"><value>Prima invia o scarta le modifiche di lavoro di {0}.</value></data>
<data name="Errors.Copies.BothLinked" xml:space="preserve"><value>Entrambe le sequenze sono collegate a {0}: integrale prima lì.</value></data>
<data name="Errors.Copies.TrashBlocked" xml:space="preserve"><value>{0} non può andare nel cestino: {1}</value></data>
<data name="Errors.Copies.DetailsUnchosen.one" xml:space="preserve"><value>Prima scegli {0} dettaglio.</value></data>
<data name="Errors.Copies.DetailsUnchosen.other" xml:space="preserve"><value>Prima scegli {0} dettagli.</value></data>
<data name="Errors.Copies.KeptUnchosen" xml:space="preserve"><value>Scegli la sequenza da tenere.</value></data>
<data name="Errors.Copies.NeedsNewerServer" xml:space="preserve"><value>{0} va aggiornato per integrare le sequenze.</value></data>
<data name="Errors.Copies.NoUploadRight" xml:space="preserve"><value>L'account del server non può caricare foto.</value></data>
<data name="Errors.Copies.NoFetchRight" xml:space="preserve"><value>L'account del server non può scaricare gli originali.</value></data>
<data name="Errors.Copies.NoEditRight" xml:space="preserve"><value>L'account del server non può cambiare i dettagli.</value></data>
<data name="Errors.Copies.NoDeleteRight" xml:space="preserve"><value>L'account del server non può eliminare queste foto.</value></data>
<data name="Errors.Copies.ArchiveOffline" xml:space="preserve"><value>L'archivio di {0} non è raggiungibile; collegalo e riprova.</value></data>
<data name="Errors.Copies.FolderMoved" xml:space="preserve"><value>{0} non è dove l'indice la colloca; riprova dopo la prossima scansione.</value></data>
<data name="Errors.Copies.NotThere" xml:space="preserve"><value>L'altro lato non ha più eliminato queste foto; nulla è andato nel cestino.</value></data>
</root>