docs(mail): qualify stale refresh and locale regression checks

This commit is contained in:
cesnimda
2026-11-16 22:31:37 +01:00
parent 207aba1a27
commit 8f9cf70d13
14 changed files with 293 additions and 0 deletions
@@ -0,0 +1,11 @@
# Linked Gmail refresh completion lifetime
16 November 2026. Source `207aba1a`, based on `64ac7e53`, branch `codex/a3-ui-10`.
An automatic linked-thread refresh could finish after leaving correspondence and start another Gmail-status read. A manual failure could notify a different workflow; a manual success used the language captured before the request. Three deterministic deferred fixtures reproduced these failures while keeping the outer toast provider mounted.
Refresh now checks the existing active job/generation before starting and after each awaited POST/read, suppresses obsolete completion/feedback and uses the existing translation ref. New job setup clears obsolete refresh history/loading. Already accepted server work is not cancelled or rolled back. Existing auto/manual behaviour, payloads, provider consent, linked identifiers, singular/plural copy and current-job refresh paths remain.
PASSED:84 distinct cases across five suites (Gmail20, recovery20, inbox41, trust-loop1, search-context2), TypeScript, scoped lint and whitespace diff check. Earlier81 overlaps84; these are three additional regressions, not165 cases. AST graph update receipt retained. No new export build or native browser/provider access: the preceding source's standard build exited1 at the Next security warning; its qualification is still open. No physical PDF, real mail, integrated security or final roadmap acceptance.
Source, canonical receipt and exact native gzip bindings are under [gmail-refresh-lifetime](evidence/gmail-refresh-lifetime/SOURCE_RECEIPTS.json). Remaining message/thread import, relink/unlink, disconnect, confirmed deletion and standalone status/choice read completion paths are independent work; this package does not claim them fixed. Broader real-job switching, native accessibility and final A3/release gates remain open.
@@ -0,0 +1,55 @@
{
"sourceCommit": "207aba1a27a6c369305223c48a5122ada2df015f",
"sourcesLfSha256": {
"job-tracker-ui/src/components/Correspondence.tsx": "f26cefe9136380371030ce837466fd23d345fd72d0d2ee10491eaf3a9231f285",
"job-tracker-ui/src/correspondence-gmail-import.test.tsx": "4a43a817b446b428adc90905f774231d762c10528b6338537e859de75699e48e",
"job-tracker-ui/src/types.ts": "bae01df8de079b16546fca1c738f6d49564befcf62ae0449b039faf61bff1158",
"job-tracker-ui/src/i18n/translations.ts": "1bef579f8bb593ed3a888780e9d3472531f93b5602a6e92d9df8fa062060c1e9"
},
"evidenceLfSha256": {
"gmail-refresh-red.txt": "18a343344ddc8423e3003c3e2dfc305e1594733ec65c8322f1a62eaa15c53dc3",
"gmail-refresh-green.txt": "59e6cdd89b5ed91d9d728fb929e4c9acb36d01ec16ae2cbbc2b625f7c4d65ca7",
"gmail-refresh-results.json": "574d68ad0e726be9ce51078fa6e36ce3c84477f9ef70a60591519e25fb67eda3",
"gmail-refresh-types.txt": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"gmail-refresh-lint.txt": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"gmail-refresh-graph.txt": "b6fba5c5b39b8be6903cd5ff51f21b3bb156208aea9b4bc230f6168f831864c4"
},
"nativeReceipts": [
{
"path": "gmail-refresh-red.txt",
"gzipPath": "gmail-refresh-red.txt.gz",
"rawSha256": "9541b333bcd091cbf8620ffbd9f92dfa33fad3db3043a8a87bb33e55bbbe684e",
"gzipSha256": "efc01ccd0ec99cd70171fee9f37df8ade1c68beafbccb3e264ca6613a2f4a232"
},
{
"path": "gmail-refresh-green.txt",
"gzipPath": "gmail-refresh-green.txt.gz",
"rawSha256": "7ac573fd361379527d4a178faa1ebfb5a3c5d64fc547ace957d009a3457cbf1c",
"gzipSha256": "72a4148f3081837ddf482fddcbc404f8edf9a305aa2956d77d5d4eda4b647da7"
},
{
"path": "gmail-refresh-results.json",
"gzipPath": "gmail-refresh-results.json.gz",
"rawSha256": "574d68ad0e726be9ce51078fa6e36ce3c84477f9ef70a60591519e25fb67eda3",
"gzipSha256": "6d32608256340bd8ff829036c4ed81310c972f221d64d5bd0bc1850d5ba4693c"
},
{
"path": "gmail-refresh-types.txt",
"gzipPath": "gmail-refresh-types.txt.gz",
"rawSha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"gzipSha256": "46b50c321b39e89a491b6727a01628c34245605a30beb3e7414c5e01cff90e6e"
},
{
"path": "gmail-refresh-lint.txt",
"gzipPath": "gmail-refresh-lint.txt.gz",
"rawSha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
"gzipSha256": "46b50c321b39e89a491b6727a01628c34245605a30beb3e7414c5e01cff90e6e"
},
{
"path": "gmail-refresh-graph.txt",
"gzipPath": "gmail-refresh-graph.txt.gz",
"rawSha256": "64beb47f84f657862bfb44d9f1059edeb09f7c4ec76b0157ad4df038969a434d",
"gzipSha256": "eba08c2094d7d04fe719e35a2ae296485fa105fd1f0a3a07e48f9cdc66c46c98"
}
]
}
@@ -0,0 +1,18 @@
Re-extracting code files in . (no LLM needed)...
[graphify watch] 470 file(s) not classified (no supported extension or shebang), skipped: .dockerignore, .env.example, .git, .gitattributes, .gitignore, 1440-en-dark-converted.gz (+464 more)
AST cache: 2480/2927 files served from cache (84%); 447 to extract
AST extraction: 100/447 uncached files (22%) [16 workers]
AST extraction: 200/447 uncached files (44%) [16 workers]
AST extraction: 300/447 uncached files (67%) [16 workers]
AST extraction: 400/447 uncached files (89%) [16 workers]
AST extraction: 447/447 uncached files (100%) [16 workers]
warning: 8 .sql file(s) contributed nothing to the graph because a dependency is missing: tree_sitter_sql not installed. Install it with: pip install "graphifyy[sql]" (#1745)
warning: 144 code file(s) yielded no symbols (0.14 MB) — a data file, or source this extractor models no symbols for: JobTrackerApi.Tests/PdfBrowserStub/Program.cs, JobTrackerApi/Program.cs, JobTrackerApi/Properties/AssemblyInfo.cs, browser-extension/tests/capture-url.test.mjs, docs/audits/2026-09-07/validation/evidence/b05-excel-probe.ps1 (+139 more)
[graphify watch] community set changed since labeling (0 saved labels, 1164 communities now; renamed 120 community(ies) by their hub). Run `graphify label` to refresh names with the LLM.
Graph has 19234 nodes (above 5000 limit). Building aggregated community view...
graph.html written (aggregated: 1164 community nodes, 3006 cross-community edges)
Tip: run with --obsidian for full node-level detail.
[graphify watch] Rebuilt: 19234 nodes, 47286 edges, 1164 communities
[graphify watch] graph.json, graph.html and GRAPH_REPORT.md updated in graphify-out
Code graph updated. For doc/paper/image changes run /graphify --update in your AI assistant.
Tip: set GEMINI_API_KEY or GOOGLE_API_KEY to use Gemini for semantic extraction.
@@ -0,0 +1,7 @@
Test Suites: 5 passed, 5 total
Tests: 84 passed, 84 total
Snapshots: 0 total
Time: 42.658 s
Ran all test suites matching src/correspondence-gmail-import.test.tsx|src/correspondence-recovery.test.tsx|src/correspondence-inbox-page.test.tsx|src/end-to-end-trust-loop.test.tsx|src/correspondence-search-context.test.ts.
Test results written to: E:\Storage\Projects\Active\temp docs\jobjakt-local-build\gmail-refresh-results.json
@@ -0,0 +1,201 @@
FAIL src/correspondence-gmail-import.test.tsx (8.128 s)
● correspondence Gmail import › linked refresh completion lifetime › an automatic refresh finishing after leaving cannot start follow-up reads
expect(jest.fn()).toHaveBeenCalledTimes(expected)
Expected number of calls: 2
Received number of calls: 3
365 | const reads = mockedApi.get.mock.calls.length;
366 | await act(async () => { write.resolve({ data: { ...refreshed, imported: 1 } }); });
> 367 | expect(mockedApi.get).toHaveBeenCalledTimes(reads);
| ^
368 | expect(screen.queryByRole('alert')).not.toBeInTheDocument();
369 | });
370 |
at Object.toHaveBeenCalledTimes (src/correspondence-gmail-import.test.tsx:367:29)
● correspondence Gmail import › linked refresh completion lifetime › manual refresh feedback respects a leave boundary
expect(element).not.toBeInTheDocument()
expected document not to contain element, found <div class="MuiAlert-message css-zioonp-MuiAlert-message">Failed to refresh linked Gmail threads.</div> instead
386 | view.rerender(dialog(42, false));
387 | await act(async () => { write.reject(new Error('obsolete refresh failure')); });
> 388 | expect(screen.queryByText(translations.en.correspondenceRefreshLinkedFailed)).not.toBeInTheDocument();
| ^
389 | } else {
390 | await act(async () => { window.dispatchEvent(new StorageEvent('storage', { key: 'uiLanguage', newValue: 'nb' })); });
391 | await act(async () => { write.resolve({ data: refreshed }); });
at toBeInTheDocument (src/correspondence-gmail-import.test.tsx:388:91)
● correspondence Gmail import › linked refresh completion lifetime › manual refresh feedback respects a language boundary
Unable to find an element with the text: Tilknyttede Gmail-tråder er allerede oppdatert.. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.
Ignored nodes: comments, script, style
<body
style="padding-right: 1024px; overflow: hidden;"
>
<div
aria-hidden="true"
>
<div
class="MuiBox-root css-0"
>
<span
aria-atomic="true"
aria-live="polite"
class="MuiBox-root css-ty8jgw"
role="status"
>
Innhold lastet.
</span>
<div
class="MuiBox-root css-vbvbop"
>
<div
class="MuiBox-root css-1821gv5"
>
<div
class="MuiBox-root css-1w1vbxm"
>
<div
class="MuiBox-root css-1o0cahp"
>
<p
class="MuiTypography-root MuiTypography-body1 css-u35b64-MuiTypography-root"
>
Synthetic linked note
</p>
<div
class="MuiBox-root css-agyrtj"
>
<div
class="MuiChip-root MuiChip-outlined MuiChip-sizeSmall MuiChip-colorDefault MuiChip-outlinedDefault css-1w2bku1-MuiChip-root"
>
<span
class="MuiChip-label MuiChip-labelSmall css-19m61dl-MuiChip-label"
>
Tråd thread-1
</span>
</div>
</div>
<div
class="MuiBox-root css-ipmqpd"
>
<span
class="MuiTypography-root MuiTypography-caption css-2qd4a1-MuiTypography-root"
>
Selskap
- Email
- 16.11.2026, 13:00:00
</span>
<button
aria-label="Slett melding"
class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-1374xo4-MuiButtonBase-root-MuiIconButton-root"
tabindex="0"
type="button"
>
<svg
aria-hidden="true"
class="MuiSvgIcon-root MuiSvgIcon-fontSizeSmall css-120dh41-MuiSvgIcon-root"
data-testid="DeleteOutlineIcon"
focusable="false"
viewBox="0 0 24 24"
>
<path
d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM8 9h8v10H8zm7.5-5-1-1h-5l-1 1H5v2h14V4z"
/>
</svg>
</button>
</div>
</div>
</div>
</div>
</div>
<div
class="MuiBox-root css-lqvd6v"
>
<span
class="MuiTypography-root MuiTypography-overline css-12l99mj-MuiTypography-root"
>
Kontinuitet i tilknyttede Gmail-tråder
</span>
<p
class="MuiTypography-root MuiTypography-body2 css-sn1rsr-MuiTypography-root"
>
Gmail-oppdateringen sjekker bare tråder som allerede er knyttet til denne jobben, slik at ny korrespondanse kan vises her uten å importere hele tråden på nytt.
</p>
<div
class="MuiBox-root css-1mcghfl"
>
<div
class="MuiChip-root MuiChip-outlined MuiChip-sizeSmall MuiChip-colorSuccess MuiChip-outlinedSuccess css-1ucuqrv-MuiChip-root"
>
<span
class="MuiChip-label MuiChip-labelSmall css-19m61dl-MuiChip-label"
>
Gmail tilkoblet
</span>
</div>
<div
class="MuiChip-root MuiChip-outlined MuiChip-sizeSmall MuiChip-colorSuccess MuiChip-outlinedSuccess css-1ucuqrv-MuiChip-root"
>
<span
class="MuiChip-label MuiChip-labelSmall css-19m61dl-MuiChip-label"
>
Tilknyttede tråder: 1
</span>
</div>
<button
class="MuiButtonBase-root MuiButton-root MuiButton-text MuiButton-textPrimary MuiButton-sizeSmall MuiButton-textSizeSmall MuiButton-colorPrimary MuiButton-root MuiButton-text MuiButton-textPrimary MuiButton-sizeSmall MuiButton-textSizeSmall MuiButton-colorPrimary css-3defe9-MuiButtonBase-root-MuiButton-root"
tabindex="0"
type="button"
>
Administrer thread-1
</button>
<div
class="MuiChip-root MuiChip-outlined MuiChip-sizeSmall MuiChip-colorWarning MuiChip-outlinedWarning css-1jxpu38-MuiChip-root"
>
<span
class="MuiChip-label MuiChip-labelSmall css-19m61dl-MuiChip-label"
>
Siste Gmail-synkronisering (list-messages) mislyktes
</span>
</div>
<div
class="MuiChip-root MuiChip-outlined MuiChip-sizeSmall MuiChip-colorDefault MuiChip-outlinedDefault css-1w2bku1-MuiChip-root"
>
<span
class="MuiChip-label MuiChip-labelSmall css-19m61dl-MuiChip-label"
>
Siste oppdatering sjekket 1 tilknyttet tråd
</span>
</div>
</div>
<p
class="MuiTypography-root MuiTypography-body2 css-1d237mf-MuiTypography-root"
>
Siste problem med Gmail-synkroni...
390 | await act(async () => { window.dispatchEvent(new StorageEvent('storage', { key: 'uiLanguage', newValue: 'nb' })); });
391 | await act(async () => { write.resolve({ data: refreshed }); });
> 392 | expect(await screen.findByText(translations.nb.correspondenceLinkedThreadsCurrent)).toBeInTheDocument();
| ^
393 | expect(screen.queryByText(translations.en.correspondenceLinkedThreadsCurrent)).not.toBeInTheDocument();
394 | expect(refreshes).toBe(2);
395 | }
at waitForWrapper (node_modules/@testing-library/dom/dist/wait-for.js:163:27)
at node_modules/@testing-library/dom/dist/query-helpers.js:86:33
at findByText (src/correspondence-gmail-import.test.tsx:392:29)
Test Suites: 1 failed, 1 total
Tests: 3 failed, 17 skipped, 20 total
Snapshots: 0 total
Time: 9.072 s
Ran all test suites matching src/correspondence-gmail-import.test.tsx with tests matching "linked refresh completion lifetime".
File diff suppressed because one or more lines are too long