fix(copies): address the owner review 6 findings
The review of the found-copies work showed pairs that could stick, jobs that could act on a pair the user had answered otherwise, and detection gaps: - forgetting a link on an address-keyed server deletes the pair and Candidate rows of that remote and resets the probe, so the sequence is found again when it is back; a Linked/Integrated row with no link is asked again - 404s count only on id-keyed servers, at most once per recheck interval - probes store the server's newest update time (copy_probes.server_newest, migration 0012) instead of comparing with this PC's clock; the lookup sample carries hashed photos by size and capture time too, for servers that have not hashed their copy - the older-server gate no longer re-compares unchanged manifests - a failed Integrate keeps its job id so a retry resumes only an untouched pair; cancel and stale plans release the pair (ReleaseAsync) - automatic photo transfers never create or retarget a sequence - a first upload files photos the server holds elsewhere into the new sequence - Unlink re-compares before keeping apart; Trash here names only true last copies; Drop... trashes one version on both sides after re-checking the other - a merge keeping the pair's other sequence swaps the dialog's columns and re-keys Different choices; Upload all reads every pair Each fix has a regression test where it makes sense. Refs #73 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
96b5b4078b
commit
fe752a0a21
33 files changed
+957
-123
No files matched your search
@@ -111,6 +111,24 @@ public sealed record CopyPlanContext(string PcName, string? ServerName, bool Can
|
||||
public sealed record TrashTherePlan(Guid CopyId, string Server, Guid RemoteId, IReadOnlyList<Guid> FrameIds, IReadOnlyList<string> Keys, int Photos,
|
||||
long Bytes, int FramesVersion, IReadOnlyList<LastCopy> LastCopies);
|
||||
|
||||
/// <summary>The dry run of moving photos of a pair's local copy to its archive trash, with the ones no other sequence of this index holds.</summary>
|
||||
public sealed record TrashHerePlan(FrameDeletePlan Plan, IReadOnlyList<LastCopy> LastCopies);
|
||||
|
||||
/// <summary>
|
||||
/// The dry run of dropping one version of a photo kept in two versions (design §4.1, Versions): the version
|
||||
/// <see cref="Key"/> goes to the trash of both sides (this PC's copy and the server's, or both local copies of a merge),
|
||||
/// the other version <see cref="PartnerKey"/> stays on both. Applied only while that other version is still held,
|
||||
/// verified by content, on both sides.
|
||||
/// </summary>
|
||||
/// <param name="Other">The other local copy's dry run (a pair of two local copies); null for a server pair.</param>
|
||||
/// <param name="RemoteFrameIds">The server's frames of the version (a server pair), at <see cref="RemoteFramesVersion"/>.</param>
|
||||
public sealed record DropVersionPlan(Guid CopyId, string Key, string PartnerKey, FrameDeletePlan Here, FrameDeletePlan? Other, Guid? RemoteId,
|
||||
IReadOnlyList<Guid> RemoteFrameIds, int RemotePhotos, long RemoteBytes, int RemoteFramesVersion, IReadOnlyList<LastCopy> LastCopies)
|
||||
{
|
||||
/// <summary>Every frame the drop moves, on both sides.</summary>
|
||||
public int Photos => Here.Frames.Count + (Other?.Frames.Count ?? 0) + RemotePhotos;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The journal of one project copied to another home: the intended name, when it was asked, the copy once made, the version
|
||||
/// the copy was made from, and the versions pushed so far (source version id to the copy's).
|
||||
|
||||
Reference in new issue
Block a user