fix(captures): a refused duplicate says the Capture does not verify when it does#1954
Note
Written by claude-opus-5-5 via Claude Code on behalf of Matt.
What happened. When duplicating a Capture is refused because the app cannot match the Capture to its signed history after an import renamed it, the window says "Only a capture that currently verifies can be duplicated". That Capture does verify; only the duplicate step cannot bind it. The message tells the operator their evidence failed verification, which is false and alarming.
Steps to reproduce.
- Import a Case Archive twice in a row on a build before Case Archive version 12, so an earlier import renamed a Capture (or strip the carried id maps from a version 12 archive).
- Open the imported Case and duplicate that Capture.
- The refusal reads "Only a capture that currently verifies can be duplicated", while the Capture's verification shows it intact.
What you expected. A message that says the Capture cannot be duplicated because its earlier import's record is not available, without suggesting the evidence failed verification.
Why this was kept out of the change that found it. The triage of issue 1017 raised it, and the change that closes 1017 (pull request 1953) carries earlier imports' records so most Cases no longer hit it, but Cases imported twice before that change still do. Rewording a refusal is outside that change's ruling.
Where it is
src/renderer/components/captures/useDuplicateCapture.ts duplicateRefusalMessage, the not_verified branch; the reason comes from captureLifecycle.ts duplicate returning { status: 'rejected', reason: 'not_verified', detail: 'entry-mismatch' }. The legacy detail already has its own message, so entry-mismatch can get one the same way.
Birdbrain version: the current main branch. Operating system: any.