feat: owner review 2 phase 4a: Reorganize sequences after import (#12)
CI / Build and test (push) Successful in 9m15s
CI / Windows tests and installer (push) Skipped
CI / YAML check (push) Successful in 6s
Release / Build, test and publish (push) Successful in 15m35s
CI / PostgreSQL 16 integration (push) Successful in 7m26s
CI / PostgreSQL 17 integration (push) Successful in 6m47s
CI / Docker image (push) Successful in 59s
Release / Server image (push) Successful in 1m24s
CI / Build and test (push) Successful in 9m15s
CI / Windows tests and installer (push) Skipped
CI / YAML check (push) Successful in 6s
Release / Build, test and publish (push) Successful in 15m35s
CI / PostgreSQL 16 integration (push) Successful in 7m26s
CI / PostgreSQL 17 integration (push) Successful in 6m47s
CI / Docker image (push) Successful in 59s
Release / Server image (push) Successful in 1m24s
- Reorganize… on the web panel and the desktop: folder, file and title templates applied to existing sequences, with a dry run and an explicit Apply that runs as a job. - One naming rule (FrameNaming) for import, upload and Reorganize. - Crash-safe plan and file journals, held plans, stale-plan refusal; exports move with their folder. - Writers refuse a folder another program moved or gave to another sequence. - Server: POST /api/v1/archive/reorganize with a bounded plan cache; template rules. - Phase 3 docs and translations merged; strings in all 38 languages. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Alberto Balbo <alberto.balbo.96@gmail.com>
This commit was merged in pull request #12.
This commit is contained in:
1 parent
9aa818ed47
commit
7e4a3b481d
416 files changed
+15304
-1572
No files matched your search
+28
-3
@@ -151,7 +151,7 @@ One line per decision: date · decision · alternative · reason.
|
||||
| 2026-10-03 | Import omits the Convert row and the profile "New" button: card profiles are born on first insertion and shared through camera profiles (settings row followed by the cards of that camera; a card without settings joins automatically). | Conversion at import / card-less profiles | A converted file breaks the hash-verified erase/format gate and immutable originals; a profile needs a card identity (§13 "rules shared by all cards of that camera"). |
|
||||
| 2026-10-03 | Import sessions merge in the session table and split per photo in Show plan (merges only into the earlier session of the same body and format). Folder and Server destinations run in the screen with a partial result on failure; a server 4xx (not 401/403) fails only that file. Automatic import always goes to this PC's archive. | New job kinds / abort on any error | No job handlers exist for those destinations; §13 lists errors per file; the archive is the gated destination for erase/format. |
|
||||
| 2026-10-03 | Format gate: every photo on the card must be verified by the job's own import records; non-photo files are listed in the typed confirmation, not blocking; the card is re-listed right before SHFormatDrive, behind a typed confirmation of the card name; a card that leaves needs a new check. | Count only DCIM photos / block on any file | Sony and Canon cards always carry camera files; §8.6 and DESIGN §4. |
|
||||
| 2026-10-03 | Archive manager: Overview (tree, tiles, charts, mass operations on the tree selection narrowed by a Camera/Status/Tag filter) and Maintenance (health with one fix per line, recent runs, duplicates, orphans); duplicates/orphans searches and retag run in-screen, cancellable and logged; rename apply is journaled and completed at the next open; Maintenance adds a database backup. No Merge/split yet (Delete… and Trash… exist since 2026-10-06, through the engine's trash). | Engine jobs for every action / Archive.html's single page | No result store for read-only reports; deleting or moving frames needs engine operations (the trash lives in the server). |
|
||||
| 2026-10-03 | (Partly superseded by the 2026-10-26 Reorganize job row: a plan its job paused, cancelled or failed is left to that job, not completed at the next open.) Archive manager: Overview (tree, tiles, charts, mass operations on the tree selection narrowed by a Camera/Status/Tag filter) and Maintenance (health with one fix per line, recent runs, duplicates, orphans); duplicates/orphans searches and retag run in-screen, cancellable and logged; rename apply is journaled and completed at the next open; Maintenance adds a database backup. No Merge/split yet (Delete… and Trash… exist since 2026-10-06, through the engine's trash). | Engine jobs for every action / Archive.html's single page | No result store for read-only reports; deleting or moving frames needs engine operations (the trash lives in the server). |
|
||||
| 2026-10-06 | Radio buttons that bind TwoWay are grouped by their shared panel, never by GroupName (kept only for chips in item templates, which bind OneWay). | GroupName on every group | WPF shares a GroupName across every window not yet connected to the screen, so the installer capture (one window per stage, each with its own view model) cross-wired Just me / All users into an endless loop; the same applies to views built in tests and captures. |
|
||||
| 2026-10-06 | Reading direction is set by ChronosWindow (constructor plus Loc.CultureChanged while shown, applied through the Dispatcher). UiLanguage keeps only a Window.Loaded class handler for plain windows such as FullScreenPreview. The Uploader's WindowDirection and Setup's own code are removed. | Keep three mechanisms (UiLanguage loop plus class handler, Uploader WindowDirection, SetupWindow code) | One place covers the client, Uploader and Setup windows created before or after a language switch. The class handler is still needed for the one non-ChronosWindow window. |
|
||||
| 2026-10-06 | Toasts are announced with a UIA notification event on the host: errors use ImportantAll (assertive), other notices use All (polite). | LiveSetting on each toast container plus LiveRegionChanged | A toast is a new element, not a text that changes, and the host's peer is always in the UIA tree, whereas an item container's peer may not be. |
|
||||
@@ -168,7 +168,7 @@ One line per decision: date · decision · alternative · reason.
|
||||
| 2026-10-06 | Index health duplicates line: after a duplicates search it shows the groups found (warning with a Mark copies fix); before any search it shows the flagged-copy count ('No copies flagged' / 'n duplicate frames' with Show) | Only reword the line to flagged copies, or hide it until a search has run | The line can never be a green tick while the Duplicates card lists groups, and it keeps the flagged-copy information that already existed. |
|
||||
| 2026-10-06 | All orphan kinds use the Warning glyph (▲ amber) | Add a neutral/info StatusKind in the shared kit | Every orphan line is an actionable issue with a fix button, and Warning is readable in both themes without a kit change. |
|
||||
| 2026-10-06 | Archive failures become a toast with the action's title, one localized cause sentence from ArchiveFailures.Cause and a Retry action that re-runs the same command; relink Retry re-opens the folder picker | Open logs as in Shell.ReportError, or retry with the same folder | BRIEF 0.2 rule 6 asks for one sentence plus one action. Retry fits these I/O failures. Re-picking the folder covers both 'drive is back' and 'wrong folder'. |
|
||||
| 2026-10-06 | Dialog failures appear as an error line (✕ Error StatusGlyph, raw text in its tooltip) with no separate Retry button; Apply stays the retry, and a failed apply re-runs the dry run | Add a Retry button to the Rename and Retag dialogs | DESIGN allows two dialog buttons at most. Re-planning shows what is left after a partial or stale apply. |
|
||||
| 2026-10-06 | (Partly superseded by the 2026-10-26 desktop Reorganize row: Rename is now Reorganize, whose Apply queues a job; the rule stays for the other dialogs.) Dialog failures appear as an error line (✕ Error StatusGlyph, raw text in its tooltip) with no separate Retry button; Apply stays the retry, and a failed apply re-runs the dry run | Add a Retry button to the Rename and Retag dialogs | DESIGN allows two dialog buttons at most. Re-planning shows what is left after a partial or stale apply. |
|
||||
| 2026-10-06 | Cancel is the default (Enter) button in the Rebuild, Rename and Retag dialogs | No default button, or Apply as default | DESIGN: the safe action is left and default. Enter in the text fields is already handled by EditBehavior. |
|
||||
| 2026-10-06 | Rebuild counts show '—' with the reason (offline sentence or failure cause) in the tooltip when they cannot be counted | Remove the two count rows when they cannot be counted | The dialog keeps the same shape, and the reason sits next to the value it explains. |
|
||||
| 2026-10-06 | Rename the Overview/Maintenance segment to 'Health' (new key Archive.View.Health; it: 'Stato') and keep the toolbar's 'Maintenance ▾' | Rename the toolbar menu to 'Tools ▾', or change the English value of Archive.View.Maintenance | BRIEF 12.5 names the toolbar menu Maintenance. A new key makes the missing translations visible in i18n check instead of leaving stale ones. |
|
||||
@@ -195,7 +195,7 @@ One line per decision: date · decision · alternative · reason.
|
||||
| 2026-10-06 | Trash layout: <archive>/.chronos/trash/<id>[-stamp] plus a <name>.json record (index row and renders). Restore re-indexes from the sidecar with the same ids, into the old folder or 'folder (n)'. A folder without its sidecar is adopted under the same id with the record's title, tags, rating and notes; a missing hero frame is dropped. | A trash in the database only, or erasing the files. | BRIEF §0.2 rule 8: nothing is erased, and sidecars stay authoritative. |
|
||||
| 2026-10-06 | Delete is refused per sequence for an offline archive, the archive root, folders holding other sequences, busy sequences, a foreign sidecar or a missing folder. Busy covers running or paused jobs on the sequence, plus archive-wide Scan, Rebuild, Import, Maintenance and Verify-all on its archive. Sequences with no folder and no frames lose only their rows. | Block only on jobs that name the sequence. | Archive-wide jobs name the archive, not the sequences, and an import's target folders are known only to its plan. |
|
||||
| 2026-10-06 | Server DELETE maps refusals to codes: 503 archive_offline, 409 sequence_busy (busy, stale plan or lease), 409 archive_root / contains_sequences / sidecar_mismatch / folder_missing / folder_in_use, 404 when the sequence vanished. | A single 409 sequence_busy for every refusal. | Clients show the right sentence, and an offline archive is a retryable service state. |
|
||||
| 2026-10-06 | Move works on the sequences of one archive at a time, as a new folder layout through MassRenamer with a dry run. | Cross-archive move (copy, verify, then trash the source). | The task names the engine's existing move and rename facilities, and there is no engine operation for a cross-archive move. |
|
||||
| 2026-10-06 | (Superseded by the 2026-10-26 desktop Reorganize row: Move… is Reorganize…, still for the sequences of one archive, applied by a job.) Move works on the sequences of one archive at a time, as a new folder layout through MassRenamer with a dry run. | Cross-archive move (copy, verify, then trash the source). | The task names the engine's existing move and rename facilities, and there is no engine operation for a cross-archive move. |
|
||||
| 2026-10-06 | Saved views are app-scope settings rows (library.view.<id>) listed in a menu next to the layout switch (show, save, rename, delete with Undo). They are not a chip row. | Chips under the toolbar. | Width at 1200 px: the filters already wrap. |
|
||||
| 2026-10-06 | The timeline is year bands with photos per month above the virtualised card grid, which stays visible. A month (click, or Enter from the keyboard) narrows to its year and scrolls to its first card once. | Replace the grid with a separate timeline list. | It reuses the virtualised grid and keeps the cards in sight (BRIEF §12.2 'timeline (year/month bands with density)'). |
|
||||
| 2026-10-06 | Origin filter: All origins / On this PC / Only on server. 'Only on server' means server sequences without a copy here; local copies that came from the server count as 'On this PC'. Remote cards count in the Year and Camera choices and in the timeline. | Filter by Sequence.Origin, which would mix local copies into 'Only on server'. | A remote card is what the user cannot open without proxies (BRIEF §4.4 mixed mode). |
|
||||
@@ -497,3 +497,28 @@ One line per decision: date · decision · alternative · reason.
|
||||
| 2026-10-26 | No folder upload on the web panel: the dialog has no `webkitdirectory` or directory picker (a test checks), and folders dropped on it are detected with `webkitGetAsEntry`, counted as *Folders skipped* and left out. Only files whose extension `server/info` lists (the new optional `extensions`, from `ImageFormatInfo.Known`, the scanner's list), not empty and within `limits.maxUploadBytes`, are taken. (Owner review 2, R3, R9.) | Upload folders; a list of extensions in JavaScript | The owner's request: importing a whole folder stays on the desktop. A copy of the list would drift, and the archive would ignore files that are not photos. |
|
||||
| 2026-10-26 | Web upload pacing: two photos and two chunks per photo at once (four of the server's eight chunks per account); a call with no answer, 429 or 503 retried after 1, 2 and 4 s; 401, 403, 507, an unknown target (404 `sequence`) and a failed self-test stop the remaining photos (*Not sent*) with the server's message; a completion refused with 409 `upload_state` is read again after 1, 2, 4 and then every 8 s, about a minute; two copies of one photo in a run go one after the other. A new target is created by one `POST /sequences`, never retried, and stays the dialog's target. Each start carries the capture time: the Exif DateTimeOriginal of a JPEG or TIFF-based file (from its first 256 KiB, every offset checked), else the file's modification time as local wall time, which the ingest uses only for a photo with no time of its own. (Owner review 2, R3.) | Send everything at once; `capturedAt` null | Room for the user's other clients; a refusal that would refuse every photo stops at once; a lost answer must not create two sequences; photos without Exif keep their order instead of taking their arrival time. |
|
||||
| 2026-10-26 | Cancel deletes, Close keeps: Cancel aborts the requests, stops the worker and deletes the uploads the run started and did not complete; an upload that failed otherwise (507 at completion, say) stays receiving and the next run resumes it (same user, hash, size and sequence), abandoned ones expiring after the upload retention. During a run Esc is held by a capture-phase listener on the document and leaving the page asks first, so only Cancel stops it. (Owner review 2, R3.) | Delete every unfinished upload on Close; let Esc close the dialog | Cancel frees the space at once; a failure the user can fix is resumed without sending the photo again; a stray Esc must not discard uploads. |
|
||||
| 2026-10-26 | Import, upload and Reorganize name photos through one rule, `FrameNaming`: a frame in its sequence, `{n}` = index + 1, the sequence as one session from its first frame, the sequence's camera and lens (its first photo's, or its creator's camera hint) for every photo, `{name}` the name on the card, `{ext}` the file's extension (the card name's when the file lost a photo extension), a frame without a capture time at the sequence's start (its first frame's time, else when it was made; never `DateTime.Now` or today). Uploads, card and folder imports (each session with its first photo's camera and lens) and the folder of a new sequence (from its first frame) use it, so a whole-folder import of two bodies, or a lens changed during a session, no longer shows in the names. Where filing could not know the sequence as it is now (`{session}` of a card's second session on, `{n}` after duplicates skipped mid-session or photos filed out of capture order, a first photo that changed), Reorganize gives other names, which its dry run lists. (Owner review 2, R7.) | Each photo's own Make, Model and LensModel; a naming of Reorganize's own | A Reorganize with the archive's own templates must plan nothing for what filing named; the sidecar keeps no camera or lens per frame; a dry run and its apply must agree on frames without a time. |
|
||||
| 2026-10-26 | Reorganize renames only photos under `originals/` whose SHA-256 is known and whose file is there, each within its own folder; photos adopted in place (outside `originals/`), never hashed or missing keep their names and are listed with the reason (`in_place`, `unhashed`, `missing`). A sequence whose sidecar cannot be read, is another sequence's or is of a newer format stays whole (`unreadable`, 0 photos), and so does every folder around it, which then claims no new folder. The folder and title templates see the sidecar's first frame, the index row only without a sidecar, and a sequence with no time known keeps its folder and title. Sequences created without photos (no folder yet) are left out of rename plans. (Owner review 2, R7.) | Rename adopted trees too; hash the photos first; move a folder without the sequence inside it | An adopted tree belongs to a layout someone else keeps; an unhashed photo can be neither checked against the plan nor followed by sync and the trash; a folder that cannot take a sequence along would leave its index row behind; today's date would move the folder again another day, and a title rename of an empty sequence failed at apply. |
|
||||
| 2026-10-26 | New file names are given in index order; a name already given, or held by a file that stays (a frame left alone, a file no frame lists, a companion that stays), gets `_2`, `_3`… before the extension, as filing does, so the same frames, template and folder always give the same names and a second Reorganize renames nothing. XMP companions (`stem.xmp`, `name.xmp`, any case) follow their photo with the same tail, a stem two frames share going with the first; `FrameCompanions` serves the trash and Reorganize alike. `UniqueNames` remembers, per name, the first number not yet taken, giving the same names in linear time (a `{title}` plan over 20,000 photos in well under a second, about 28 s before); import, ingest and Reorganize use it. (Owner review 2, R7.) | Refuse a plan with colliding names; search from `_2` for every photo | Deterministic and idempotent; companions keep describing their photo; a quadratic search made a large dry run outlast an HTTP timeout. |
|
||||
| 2026-10-26 | A step's file renames run under `.chronos/rename-files.json` (the frames version, the phase, every file's old, temporary and new name): every file first to a hidden temporary name beside it (`.chronos-rename-<token>-<n>.tmp`), the journal then at phase 2, then every file to its new name, never with overwrite; then the sidecar (frames version + 1, frame order and ids unchanged, so an editor holding the old version reloads once), the index (`FrameRepository.RenameFilesAsync`, only from the version the renames started at), and the journal goes. A failure while files move puts every file back; when one cannot go back, the journal completes the renames at once. After a crash the next writer of the sequence (`SequenceWriter.ReadLocked`; the plan's resume; an archive open for a held plan's unfinished steps) rolls forward, safe to run again from any point: phase 1 becomes phase 2 once every file is at its temporary name, a new name taken meanwhile sends the photo and its companions together back to their old names or the first free `_n` (journaled before they move), and the journal stays while a temporary file is left; the index follows at the plan's resume or the next scan. (Owner review 2, R7.) | Rename one file at a time in place; roll a crash back | Chains (A→B, B→C) and swaps never meet a name another file holds and nothing is ever written over; once files reached their new names, rolling forward is the shorter way to a sidecar that matches the disk. |
|
||||
| 2026-10-26 | Each step (a sequence and those nested in a folder that moves with it) takes the sequence leases, then the thumbnail leases, by id, and checks under them, before anything of it moves: the sequences where the plan has them, no sequence indexed since inside a folder that moves, nothing at its new folder (`TargetTaken`: a folder on disk, or an index row there, around or inside it), no sidecar of a newer format to rewrite, the title it was planned from where it changes the title or names the folder or files after it (`NamedByTitle`), the folder and title the templates give from the settled sidecar, and the file renames planned again (by digest). Those that refuse (all but the names and the file renames) also run up front, without the leases, before a fresh or a held plan starts. Then the folder moves, every index row of the step follows (folder and title, frame paths, export paths, one transaction), and only then are files renamed; once its folder moved, a step goes to its end whatever is cancelled. A sidecar that cannot be read or written after the move still has its row follow (title kept, no scan stamps), every sequence of the step is told, and the step fails so the job holds the plan. (Owner review 2, R7.) | Rename the files first; check only when the plan starts | Nothing of a step is half-applied when the plan no longer fits, the index never names a folder the sequence left, and no writer works in a folder while it moves or its files are renamed. |
|
||||
| 2026-10-26 | A Reorganize is confirmed by its plan's fingerprint: the SHA-256 of the file template and of the steps as the dry run shows them (ids, folders, titles, carried, file count, samples, what stays and why) with each step's file renames as one digest (`RenameStep.FileDigest`), not the frames version. The `move` job's parameters (`MoveJobParameters`) carry the templates, the sequences that have a step in the order the plan was made for (which decides the folder that gets " (2)") and the fingerprint, no file list; the job plans again and applies only a plan of the same fingerprint, else fails with "The archive changed after this plan was made" and nothing changes, naming in its log a sequence deleted since. The server answers a confirmation whose plan differs 409 `plan_changed` with the fingerprint now. (Owner review 2, R7.) | Store the plan or its file list in the job; include the frames version | The change made is exactly the one shown (destructive operations rule); the parameters stay small for 100,000 photos; photos uploaded under the names the plan leaves them (the archive's file template is the Reorganize's, the usual case after saving templates) must not refuse it. |
|
||||
| 2026-10-26 | Photos changed after the plan (received, removed, hashed or copied in, so that the renames planned again differ) refuse nothing: under its leases that sequence keeps its file names (`FilesKept`), and its folder and title change as planned while the templates still give them from its first photo as it is now (the plan journals its folder and title templates; `RenamePlanner.Names`, `Gives`: the expansion or its " (n)"); otherwise its title and file names stay, and its folder too (`Dropped`; `TitlesKept` when an interrupted run moved its folder already), and so do the sequences its folder was to carry (`CarriedKept`). A sequence so left inside the folder of a later step that moves goes with that folder (next row); the folder around it is never kept in place for it. The other steps go on, and the job fails at the end saying how many sequences were not reorganized as planned. A title edited since, a folder taken, a sequence moved or indexed inside a moving folder, or a sidecar of a newer format refuse the rest of the plan instead (a plan an interruption left drops that step, or keeps what no longer fits). A plan journaled before its templates were kept is applied as planned. (Owner review 2, R7.) | Refuse the step, or the whole plan, as soon as a photo arrives | A time-lapse camera uploading every few seconds would make a file Reorganize impossible; a folder or title must never be named after a photo that is no longer first; a user's title edit is never written over. |
|
||||
| 2026-10-26 | A sequence of the plan that an earlier step left as it was (it changed after the plan, such as photos that make the templates name it otherwise now, or, when a plan resumes, whatever drops a step), or that stayed with a folder that was to carry it, is taken along by a later step whose folder moves while the index still has it inside that folder (at its own folder, or where an interrupted run's move took it): `MassRenamer.LeftInsideAsync` adds it to that step as a carried sequence with its title and file names as they are, locked, leased, moved and recorded with the folder. The tally counts it as titles kept (`TitlesKept`, logged "Title and file names kept, changed after the plan") instead of dropped; one whose carrier stayed is no longer kept when it was only to move, and is titles kept when it was to be retitled or renamed too; one a newer Chronos wrote stays counted as newer. Before a held plan resumes, the check without the leases (`RefuseStaleAsync`) accepts inside each moving folder only the sequences of the remaining steps and the completed ones so left there; any other refuses the plan, which is given up. (Owner review 2, R7.) | Refuse the outer step, which failed the plan at every retry; keep the outer folder in place with all it holds | Nested sequences move out first, so one that stayed was found inside the outer folder as a stranger and the plan stayed held for ever; the outer folder's change does not depend on the nested one's, and moving the nested sequence with its index row leaves no row behind. |
|
||||
| 2026-10-26 | Reorganize is a job on both hosts: `JobKind.Move` (stored 14, wire `move`, now labelled *Reorganize*), user priority, target the archive, handled by `MoveJobHandler` through `ArchiveService.CreateJobHandlers`; the desktop dialog keeps its dry run in-window and Apply queues the job. Progress counts the steps that change; the checkpoint is `plan:<id>` once the plan's journal exists. Paused or cancelled by the user, or failed, the job stops between two steps and holds the plan (`RenameJournal.Held`): an archive open leaves it to the job (completing only file renames a step left half-way), and the job's resume or retry completes it while it still fits, else gives it up (journal deleted). A yield to another job or a host that stops leaves it unheld, completed at the next open. A failed job whose plan is over (completed with sequences kept, or given up) checkpoints `applied`, so its retry plans again; one that failed because the archive's volume went away keeps its plan, and its retry completes it once the volume is back. A plan journal not found on an archive that cannot be reached (`ArchiveVolume.Probe` offline) tells nothing: a failed job then keeps its `plan:<id>` checkpoint instead of `applied`, and a retry while the archive is offline fails as offline ("The archive … is offline") instead of logging that the plan was completed at an archive open and ending done. Deleting sequences of the archive is refused while the job runs or is paused. (Owner review 2, R7.) | Apply inside the dialog, as the 2026-10-03 and 2026-10-06 rename dialog did; complete held plans at the next open | A Reorganize can rename every photo of an archive: as a job it is paused, resumed after a restart, followed and retried in Jobs, on the same path as the panel; an archive open must not finish behind the user's back what they paused; an unplugged drive must not make a held plan look completed. |
|
||||
| 2026-10-26 | The plan's journal keeps a tally of the whole plan (`RenameJournal.Done`: changed, files, dropped, files kept, titles kept, files busy, newer, carried kept), so the job log covers every run: "Sequences changed: N, files renamed: M", then one line per sequence not changed as planned, with why. The job then fails with one error: kept first ("changed after the plan"), then newer (a sequence file from a newer Chronos, met only when resuming), then busy (a photo in use or its new name taken); sequences kept because the folder around them stayed follow their carrier's reason. (Owner review 2, R7.) | Report only the last run; one generic error | A plan applied over several runs reports what it did as a whole, and each sentence must be true. |
|
||||
| 2026-10-26 | Each sequence a Reorganize changed is told through `ArchiveServiceOptions.SequenceChanged` (change `reorganized`) once its step is journaled, by its job or by an archive open that completed an interrupted plan, and at once for a step that failed after its folder moved; a failure to tell is logged, never passed on. The server publishes `sequenceChanged` `reorganized` with the row's versions (its open at start has no hook: no client is connected yet); the desktop raises `AppServices.SequenceReorganized`, and an editor open on that local sequence reloads where it is now while the job goes on (`LocalSequenceSource` reads the frames again when the folder changed while it listed them). (Owner review 2, R7.) | One event when the job ends | Steps done before a pause or a failure are told; an open editor would otherwise decode from paths that moved. |
|
||||
| 2026-10-26 | A folder move rebases the archive-relative paths of the exports inside it in the same transaction as the sequence row and its frames (`RenderRepository.RebaseFolderAsync`, `ArchiveIndexer.RebaseRendersAsync`). An export is a file, or a folder for an image sequence. The sequence's own exports follow unless one was written at the old place after the move (there and not at the new place, the old folder not another sequence's now), and so does one whose old path another sequence's export now names; another sequence's export saved inside (the Export folder picker) follows only when it moved with the folder, and never one of the sequence that holds the old folder now (next row); absolute paths and other folders stay. A scan that finds a sequence in another folder (another index's Reorganize, a folder moved by hand) applies the same rule. (Owner review 2, R7.) | Leave render rows to be recorded again; rebase by sequence only | Exports must stay downloadable and syncable on every host after a move, and a row must keep naming where its file is. |
|
||||
| 2026-10-26 | When another index moved a sequence out of its folder and another sequence into that folder, this index's rebase of the first one reads once which other sequence the old folder holds now (`SequenceFolders.OtherSequence`, the id its sidecar names): the first sequence's own exports follow to its new folder even when an export of that name is at the old path (it is the other sequence's), a render row of the sequence that holds the old folder never follows, whatever the scan order, and no other row counts as left behind at the old path while that folder holds another sequence (a third sequence's export saved there through the picker follows when its file moved with the folder) (`RenderRepository.RebaseFolderAsync` gives the rule each row's owner). Known limitation: an export that sequence had saved through the Export folder picker into the first one's folder, before it took that folder, keeps naming the old path; the file is intact in the first sequence's new folder, and no scan repairs the row. (Owner review 2, R7.) | Let every row under a taken old folder follow; keep any row whose path still holds a file | When the scan rebased the holder first, its row then followed the other sequence and named that sequence's file, its own export left without a row for good; a row must never name another sequence's file, and the case left out needs an export saved into another sequence's folder before two moves by another program. |
|
||||
| 2026-10-26 | A render job's checkpoint records the sequence's archive-relative folder with the output it chose (`RenderCheckpoint.Folder`; older checkpoints read it as null). On resume, a crash's leftovers are rebased by a folder move and removed only inside the sequence's current exports or outside the archive (an export folder chosen on a client); anywhere else in the archive they are left alone and the render takes the next free name. (Owner review 2, R7.) | Delete the pending output at the path the checkpoint recorded | After another program moved the sequence and another sequence into its folder, that path was the other sequence's export, deleted on resume; leftovers of a crash into an export folder chosen inside the archive are no longer cleaned up, the price of never deleting where the sequence is not. |
|
||||
| 2026-10-26 | *Download originals* restores the originals flagged missing after its transfers, under the sequence's lease, at each frame's path in the folder the index has then, and only when that folder holds the sequence (`SequenceFolders.Holds`); otherwise it restores nothing, keeps the staged copies for the retry and fails with `Errors.Archive.FolderMoved` after its other work. (Owner review 2, R7.) | Restore at the path read when the job started, without the lease | A folder moved by another program sent the photo into the sequence that took the folder (adopted there at its next scan) or recreated the moved-away folder; after this PC's next scan the retry restores into the new folder. |
|
||||
| 2026-10-26 | A writer takes a sequence's folder from the index row read under the sequence's lease (`SequenceWriter.FolderAsync`; renders a client or a node sends through `ArchiveService.UnderLeaseAsync`), so it writes where a Reorganize put the sequence and never creates the folder it left. A folder another index moved is not where this index has it until its next scan, and neither is one that holds another sequence now (next row): *Take server* and *Save both*, exports fetched by sync, proxies made and a render job as it starts refuse it with "The folder of this sequence is not where the index has it; try again after the next scan" (`Errors.Archive.FolderMoved`), proxies received with 404 `frame`, the server's render filing with 503 `folder_moved` (`FolderMovedException`) and the editor's save with "This sequence is no longer in the archive"; a deep analysis records nothing. Render filing that meets a sequence held past the lease wait, an offline archive or such a folder answers 503 (`sequence_busy`, `archive_offline`, `folder_moved`) and puts the upload back to receiving, the node keeping its job while its client retries (about 30 s; a node then reports the job failed, and its retry renders again); a proxy upload answers 503 `sequence_busy`, or 404 `frame` once its sequence or folder is gone. (Owner review 2, R7.) | Let writers create the old folder again; answer 409, or 500 as before | A folder created again holds files no index row names; `ChronosClient` retries only 503s and a render node fails its job on any other error, which would discard a finished render (a 500 left the upload stuck in Committing until a restart). |
|
||||
| 2026-10-26 | A sequence is in the folder the index has for it only while that folder exists and its sidecar, when it has one, names no other sequence (`SequenceFolders.Holds`; a sidecar that cannot be read does not count as another's). Every writer that files into a sequence's folder asks it, so a folder another index moved the sequence out of, and another sequence into, is refused exactly like a missing folder until this index's next scan: settings sync and *Take server* (nothing written), *Save both*'s copy and its clean-up (which deletes nothing in such a folder), exports fetched by sync (the download stays staged), the server's render filing, a render job as it starts, proxies received, proxy passes, the deep analysis's checkpoint and the editor's save; a thumbnail pass refuses a sidecar of another sequence before it opens the pack. (Owner review 2, R7.) | Check only that the folder exists; check the sidecar's id in some writers | With only the folder checked, *Take server* wrote the server's settings into the other sequence's `project.json`, *Save both* wrote this PC's copy into its `.chronos` and a render sent for the sequence was filed among its exports; one check shared by every writer leaves none out. |
|
||||
| 2026-10-26 | The proxy pass holds the thumbnail lease one batch at a time: a quarter of the lease wait (30 s by default), at least one photo, then lets it go for 750 ms (1.5 × `LeaseFile.LongestPoll`, 500 ms) and reads the folder, sidecar and companions again; a folder gone, or holding another sequence now, stops the job with the folder-moved error (resumed from its checkpoint after the scan), and photos changed between batches leave `ProxiesBuilt` unset. File renames take the thumbnail leases too; the thumbnail pass still holds its lease for its whole run. Cost: up to about 2.5 % on long passes. Another process's thumbnail pass may take the lease in a gap, and one longer than the lease wait then fails the running proxy pass, which resumes from its checkpoint. (Owner review 2, R7.) | Hold the lease for the whole pass; no lease | Another program's Reorganize, sequence deletion or pack compaction waits for one batch instead of failing after two minutes behind an hours-long pass, and no pass writes proxies into a folder that moved. |
|
||||
| 2026-10-26 | A sequence keeps its folder when it already is what the template gives, or that name with the " (n)" filing or an earlier Reorganize gave it, in the template's case; a change of case only is planned while no other folder holds that exact name (another sequence's, or on a case-sensitive file system a folder on disk beside the sequence's own: `RenamePlanner.ExistsExactly` compares every level exactly) and moves through a temporary name. No two sequences of a plan get folders that differ only in case. Under the step's leases a case-only target that now exists beside the sequence's own folder refuses the step (dropped when resuming), as `MoveFolder` would; a change of case in an outer level moves on every file system. (Owner review 2, R7.) | Compare folder names without case; make every target unique again | A second Reorganize must plan nothing (a folder flipped between " (2)" and " (3)" before); NTFS ignores case and Linux does not; a plan that fails at every archive open must never be journaled. |
|
||||
| 2026-10-26 | Template rules (`TemplateRules`, checked on three sample photos two seconds apart): a folder template may not write a level scans never enter (`ReservedFolder`: starting with `.`, or `originals`, `proxies`, `exports`, `.chronos`); a file template may hold no slash (`FileSeparator`), must keep the photo's extension (`Extension`: `PathTemplate.KeepsExtension`, the extension appended or after `.{ext}`) and must give a session's photos different names (`NotUnique`). What a template does not write itself is made safe instead: a folder level a title gives that scans skip gets a leading `_` (`ExpandFolder`, for import, upload and Reorganize alike), a file name over 200 characters is shortened before its `.{ext}` without splitting a surrogate pair, and a title template expands as text (`ExpandText`: control characters as spaces, at most 200 characters, no file-name sanitizing). Each rule has its sentence (`Errors.Template.<Rule>`). (Owner review 2, R7.) | Check only that a template parses | `{n}{ext}` drops the dot, and with it the extension every decoder goes by; a folder scans skip vanishes from a rebuilt index; repeating names fill a session with `_2`, `_3`; titles became `Paris_ night`. |
|
||||
| 2026-10-26 | The rules hold wherever a template is typed or sent: the desktop's Settings › Archive, Import and Reorganize fields (`NamingPreview`), the server's Reorganize and `PUT /archive/settings`, and the archive engine (`ArchiveSettings.Problem`, `CheckTemplates`). A template `archive.json` already holds (saved by 0.1.0-rc.5 or earlier) is held to them only when an edit changes it: the engine's `UpdateSettingsAsync` and the server's PUT check the rules only for templates that differ from the stored ones, every template still having to be non-blank, valid and expandable (the PUT compares with the archive as the server last read `archive.json`; when that file changed since, a desktop's edit say, and the engine refuses a template the form still sends, the answer is still `invalid_template` with the rule, never 409 `archive_policy`); `CreateAsync`, and so adopting a new folder, holds both to every rule (this PC's templates saved by an older version then refuse Welcome › Create, the toast naming the rule, fixed in Settings › Archive). A broken rule is a `TemplateRuleException` (an `ArgumentException` naming the field, with the rule), whose sentence the desktop's toasts show; the API's `invalid_template` details are `<field>:<rule>` (`fileTemplate:extension`) with that sentence in the request's language, a blank or invalid template keeping the bare field and the generic message. (Owner review 2, R7.) | Refuse every save while a stored template breaks a rule; check the rules in the user interfaces only | A pre-rules template must not block an edit of the name, the proxy size or the other template, on the desktop or the panel; neither the engine nor the server accepts from another client what the fields refuse. |
|
||||
| 2026-10-26 | The server keeps Reorganize dry runs (`ReorganizePlanCache`), keyed by the archive, the selection (all, or the ids in their order), the templates and `SequenceRepository.GetStampAsync`: a SHA-256 of what the planner reads from the index (every row's id and folder; for the planned rows their title, first capture, camera make and model, lens, photo count, frames version and how many of their photos are hashed; for others inside a planned folder their title). Uploads into other sequences, ingest status writes, verifies of other sequences and tag or note edits keep a plan; a verify that hashed planned photos plans again. A plan, or a refusal (`nested_target`, `not_found`), is kept 5 minutes from when it was made (a timer per plan, checked again on access); failures and stopped plans are not. Plans are made apart from the request (a request cut off only stops waiting), once per key, at most 2 at once (`Concurrency`) and 8 kept or being made (`Capacity`: a new one lets go the kept plan asked for first, else the one being made asked for first, which stops); one still being made 15 minutes after it was asked (`PlanTimeout`, the wait for a turn included), let go, or running when the server stops is cancelled and answered 503 `plan_dropped`. The confirmation forgets its key once the job is queued. (Owner review 2, R7.) | Plan again at every request; plan in a background job with progress | An `all` dry run reads every sidecar and photo folder, minutes over SMB, and behind a proxy's timeout it was never shown; the job plans again and compares fingerprints, so a kept plan that is stale can only fail, never change what the dry run did not show (a change made on disk alone answers 202, then the job fails changing nothing). |
|
||||
| 2026-10-26 | `POST /api/v1/archive/reorganize` (ManageArchive): exactly one of `sequenceIds` (1–1,000) and `all`, a null template kept, at least one given; a dry run answers the plan (`ReorganizePlanDto`: steps with folders, titles, carried, frames version, file count, up to 3 samples and what stays, its reason in snake case with a sentence in the request's language; totals; fingerprint); the change answers 202 with the `move` job. 400 `bad_request` (`sequenceIds`, `templates`, `fingerprint`), `invalid_template`; 404 `not_found` (`sequence`); 409 `nested_target` (details: the folder), `plan_changed` (details: the fingerprint now), `job_unavailable`; 503 `archive_offline`, `plan_dropped`. Audited `archive_reorganized` ("sequences · files · folder, file and title templates"), which the panel's audit log and Dashboard show as a sentence. (Owner review 2, R7.) | Separate rename and move endpoints; every planned name in the answer | One request carries the three templates as both programs do; a dry run of 100,000 photos answers counts and samples, not every name. |
|
||||
| 2026-10-26 | Panel: the Library's *Reorganize…* sends the selected ids, up to 1,000, and `all: true` only above that while the selection is exactly *Select all* without a filter and the total has not changed; any other larger selection is refused with a toast, never split into several plans or jobs. The dialog's switches start on for the parts with a template (Titles off and empty, the archive having no title template; from the Archive page's toast only the changed parts), templates are sent trimmed, a dry run runs 400 ms after typing (Enter at once) with one request in flight and a change meanwhile planned right after, an older request's refusal is not shown, and Apply runs only while the shown plan is the fields' and changes a sequence. The confirmation has two buttons and asks for nothing typed (nothing is deleted); a different plan answered during it is shown, not applied. `toast(message, isError, action)` takes an optional link or button; such toasts stay 15 s and pause under the pointer or the keyboard focus. (Owner review 2, R7.) | Split a large selection into several jobs; a typed confirmation | One dialog is one plan and one job, and separate plans could give two sequences one destination; a typed word is for what cannot be undone. |
|
||||
| 2026-10-26 | Desktop: one *Reorganize…* dialog replaces Rename… and Move… of the Archive manager and Move… of the Library, for the sequences of one archive as Move was: Folders and File names on with the archive's templates (read again from the index when it opens), Titles off with `{title}`; the dry run follows the typing (400 ms; Enter or leaving a field plans at once unless that dry run is on screen or under way, so a click on Apply is never turned off under it), and only the latest dry run publishes its result. After Settings › Archive saves a new folder or file template into an archive with sequences, a toast offers *Reorganize…* for every sequence with the changed parts on, one offer per archive, a change made while its toast is up (8 s) joining it (`ReorganizeOffer`, `Toast.Closed`); on the Archive screen an open dialog is never replaced: Reorganize waits, says so, and opens when it closes. The old Rename and Move keys were pruned from every language (`i18n prune`); the capture scene is `archive-reorganize-*`. (Owner review 2, R7.) | Keep Rename (titles) beside Reorganize; a modal question or an automatic Reorganize after a template change | One concept and one button for how filed sequences are named, with the same three templates as the panel; templates only name what is filed next, so a toast offers without interrupting and nothing moves without the dry run; a new key shows as untranslated instead of 36 languages keeping "Move". |
|
||||
Reference in new issue
Block a user