fix(fathom): skip getDocument when header cache is missing#4859
Conversation
… emitting a degraded, un-refreshable record
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
PR SummaryLow Risk Overview When a header is present, hydrated documents now always use the cached title, This guards standalone or retry hydration without a populated cache; normal sync still fills headers in Reviewed by Cursor Bugbot for commit 41b3413. Configure here. |
Greptile SummaryThis fix adds an early-return null guard in
Confidence Score: 5/5Safe to merge — the change is a targeted null guard that only affects the edge case where The change is small and the logic is straightforward: fetch transcript/summary, then bail out early if the header cache is empty. The No files require special attention. Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[getDocument called] --> B{externalId present?}
B -- No --> Z[return null]
B -- Yes --> C[Fetch transcript]
C --> D{transcript ok?}
D -- 404 --> Z
D -- error --> E[throw → catch → return null]
D -- ok --> F[Fetch summary optional]
F --> G{hasTranscript or hasSummary?}
G -- No --> Z
G -- Yes --> H[readCachedHeader from syncContext]
H --> I{header found?}
I -- No --> J[warn log → return null]
I -- Yes --> K[formatMeetingContent]
K --> L{content non-empty?}
L -- No --> Z
L -- Yes --> M[return ExternalDocument]
Reviews (1): Last reviewed commit: "fix(fathom): skip getDocument when heade..." | Re-trigger Greptile |
Summary
Fathom getDocumentpreviously emitted a degraded record when the cachedFathomMeetingHeaderwas missing —'Untitled Fathom Meeting'title, nosourceUrl, and a timing-lesscontentHash(fathom:${id}) that would never trigger re-indexing on changenull(with a warn log) when the header is absent, so an incomplete, un-refreshable record can't pollute the index. In the normal sync flowlistDocumentsalways populates the header cache beforegetDocumentruns, so this only guards the edge case (standalone/retry call with no populatedsyncContext) — and the meeting is retried on the next sync once the cache is populatedType of Change
Testing
Tested manually — type-check clean, lint clean, 100 connector tests pass.
Checklist