Skip to content

[$250] [DEV] Expense report/thread not loading properly #96718

Closed as not planned

Description

@izarutskaya

If you haven’t already, check out our contributing guidelines for onboarding. To join our Slack channel, fill out this form.


Version Number: 9.4.41-4 (DEV only)
Reproducible in staging?: Needs Reproduction
Reproducible in production?: Needs Reproduction
If this was caught during regression testing, add the test name, ID and link from BrowserStack:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: @bernhardoj
Slack conversation (hyperlinked to channel name): #expensify_bugs

Action Performed:

  1. Open the App on DEV
  2. Go to any expense report or thread

Expected Result:

The report or thread is loaded correctly, showing the report/thread name

Actual Result:

Infinite loading, loaded but with incorrect name or missing parent navigation subtitle (From "..,")

Workaround:

Unknown

Platforms:

Select the officially supported platforms where the issue was reproduced:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari

Screenshots/Videos

web.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
Issue OwnerCurrent Issue Owner: @thesahindia

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on Jul 22, 2026
  2. removed
    BugSomething is broken. Auto assigns a BugZero manager.
    on Jul 24, 2026
  3. added
    BugSomething is broken. Auto assigns a BugZero manager.
    and removed
    BugSomething is broken. Auto assigns a BugZero manager.
    on Jul 24, 2026
  4. MelvinBot commented on Jul 24, 2026

    @MelvinBot
    Contributor

    Proposal

    Please re-state the problem that we are trying to solve in this issue.

    On DEV, opening any expense report or thread shows one of: infinite loading in the header, a loaded-but-incorrect report name, or a missing parent-navigation subtitle (From "…").

    What is the root cause of that problem?

    All three symptoms collapse to a single source of truth: the persisted reportAttributes Onyx derived value. The header title, the loading skeleton, and the From "…" subtitle all read the per-report reportName from it, so if that derived value doesn't hold a correct name for a report (and its parent), you get exactly these three symptoms:

    • Skeleton gate is purely isLoading = !report?.reportID || !title — HeaderView.tsx:282. Empty derived name → infinite loading.
    • getReportName falls back to the raw, often-stale report.reportName when the derived name is missing — ReportNameUtils.ts:1131. Stale derived value → incorrect name.
    • The From "…" subtitle uses the parent report's derived name and is hidden entirely when it's empty (ParentNavigationSubtitle.tsx:152-154).

    Why DEV-only: reportAttributes is persisted to disk — it is not in the RAM-only list (setup/index.ts:63). On launch it restores the on-disk value and recomputes incrementally: it seeds from the old value and only rebuilds reports that appear in the change deltas — reportAttributes.ts:306 and :560. A developer running an unreleased build (9.4.41-4) and switching branches accumulates a stale or wrong-schema persisted derived value; untouched reports keep their stale/empty names forever and are never rebuilt. Staging/production users on fresh data rarely hit this.

    What changes do you think we should make in order to solve the problem?

    Invalidate the persisted reportAttributes derived value and force a full recompute when it can't be trusted — e.g. add a schema/version stamp to the derived value and discard-then-fully-recompute on mismatch (rather than restoring and only updating incrementally). This makes a schema change or corrupted on-disk value self-heal on the next launch instead of silently persisting stale names.

    Diagnostic to confirm before implementing (medium confidence)

    This needs a DEV runtime confirmation to pin the exact trigger. Ask the reporter to check the DEV console for:

    • Log.info breadcrumbs from the derived engine — "restored from disk" vs a fresh compute, and any [OnyxDerived] compute for … threw (a swallowed throw in the compute would leave names stale for all reports — OnyxDerived/index.ts).
    • Whether clearing the local Onyx DB / storage fixes it (would confirm the stale-persisted-value theory).
    • Whether OpenReport actually resolves against the local backend (isolates the skeleton symptom, which is separately driven by isLoadingInitialReportActions).

    A candidate secondary trigger is a __DEV__-only throw along the render/compute path (e.g. RenderHTML inside a <Text>, RenderHTML.tsx:47) getting swallowed by the derived compute's try/catch — which would also leave names unset on DEV only. The console error text would distinguish this from the stale-value path.

    Key files

    Next Steps for Contributor+ team:
    To accept: @MelvinBot implement [this](https://github.com/Expensify/App/issues/96718) to create a draft PR.
    To refine: @MelvinBot <your feedback>
    To reject: Explain why you are rejecting Melvin's proposal.

  5. added
    ExternalAdded to denote the issue can be worked on by a contributor
    on Jul 24, 2026
  6. added
    Help WantedApply this label when an issue is open to proposals by contributors
    on Jul 24, 2026
  7. ahmdshrif commented on Jul 24, 2026

    @ahmdshrif
    Contributor

    Proposal

    Please re-state the problem that we are trying to solve in this issue.

    On DEV, opening an expense report or thread intermittently shows infinite loading, the wrong report name, or a missing parent-navigation subtitle ("From …").

    What is the root cause of that problem?

    The name shown for a report comes from the report_attributes derived Onyx value, read via getReportName(report, derivedReportName), which falls back to report.reportName ?? '' when the derived name is absent:

    function getReportName(report?: Report, derivedReportName?: string): string {
    if (!report?.reportID) {
    return '';
    }
    return derivedReportName ?? report.reportName ?? '';
    }

    That derived value recomputes incrementally — only reports whose keys land in sourceValues/updates get re-derived; others keep their prior value:
    // if we already computed the report attributes and there is no new reports data, return the current value
    if ((useIncrementalUpdates && !sourceValues) || !reports) {
    return currentValue ?? {reports: {}, locale: null};
    }
    const reportUpdates = sourceValues?.[ONYXKEYS.COLLECTION.REPORT] ?? {};
    const reportMetadataUpdates = sourceValues?.[ONYXKEYS.COLLECTION.REPORT_METADATA] ?? {};
    const reportActionsUpdates = sourceValues?.[ONYXKEYS.COLLECTION.REPORT_ACTIONS] ?? {};
    const reportNameValuePairsUpdates = sourceValues?.[ONYXKEYS.COLLECTION.REPORT_NAME_VALUE_PAIRS] ?? {};
    const transactionsUpdates = sourceValues?.[ONYXKEYS.COLLECTION.TRANSACTION];
    const transactionViolationsUpdates = sourceValues?.[ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS];
    const policyTagsUpdates = sourceValues?.[ONYXKEYS.COLLECTION.POLICY_TAGS];
    let dataToIterate = Object.keys(reports);
    // check if there are any report-related updates
    const reportUpdatesRelatedToReportActions = new Set<string>();
    for (const actions of Object.values(reportActionsUpdates)) {
    if (!actions) {
    continue;
    }
    for (const reportAction of Object.values(actions)) {
    if (reportAction?.childReportID) {
    reportUpdatesRelatedToReportActions.add(`${ONYXKEYS.COLLECTION.REPORT}${reportAction.childReportID}`);
    }
    }
    }
    // When only some accounts changed their name, refresh just the reports that use those accounts
    // Skipped when we're already refreshing everything (first load or a
    // locale change); in that case useIncrementalUpdates is false and the full scan below handles it.
    const personalDetailsChangedReportKeys: string[] = [];
    if (displayNameChanges instanceof Set && useIncrementalUpdates) {
    for (const reportKey of Object.keys(reports)) {
    const report = reports[reportKey];
    if (report && reportReferencesAccountIDs(report, displayNameChanges)) {
    personalDetailsChangedReportKeys.push(reportKey);
    }
    }
    }
    const updates = [
    ...Object.keys(reportUpdates),
    ...Object.keys(reportMetadataUpdates),
    ...Object.keys(reportActionsUpdates),
    ...Object.keys(reportNameValuePairsUpdates),
    ...Array.from(reportUpdatesRelatedToReportActions),
    ...policyChangedReportKeys,
    ...personalDetailsChangedReportKeys,
    ];
    if (useIncrementalUpdates) {
    // if there are report-related updates, iterate over the updates
    if (updates.length > 0 || !!transactionsUpdates || !!transactionViolationsUpdates || !!policyTagsUpdates) {
    dataToIterate = [];
    if (updates.length > 0) {

    This gate was just reworked (derived-values optimization #96320 + onyx-store reland #96523) right before this DEV-only report. When a freshly-opened report's name depends on data that arrives without pushing that report's own key into updates (e.g. personal details / parent report resolving after the report), its derivedReportName is never computed. getReportName then returns ''/stale, and getParentNavigationSubtitle (reading the same state) yields no "From …" subtitle.

    What changes do you think we should make in order to solve the problem?

    Guarantee the visible report is always re-derived. In reportAttributes.ts, when useIncrementalUpdates is on, push the current report's key into dataToIterate if its report_attributes entry is still missing (else fall back to a full scan):

    if (currentReportID && !currentValue?.reports?.[currentReportID]) {
        updates.push(`${ONYXKEYS.COLLECTION.REPORT}${currentReportID}`);
    }

    Regression: this only adds the on-screen report on cache-miss, so it never skips an already-derived report and adds at most one entry.

  8. mukhrr commented on Jul 24, 2026

    @mukhrr
    Contributor

    🚨 Edited by proposal-police: This proposal was edited at 2026-09-02 06:14:04 UTC.

    Proposal

    What is the root cause of that problem?

    OnyxDerived.init() restores each derived value from disk, then opens the dependency connections. Until the last one initializes, every callback is thrown away before it is recorded:

    // Before all connections are established, don't write to Onyx.
    // This prevents overwriting a valid disk-cached value with empty defaults,
    // and avoids N-1 unnecessary Onyx writes during initialization.
    // We still update dependencyValues via setDependencyValue so data accumulates correctly.
    if (!areAllConnectionsSet) {
    Log.info(`[OnyxDerived] not all connections set for ${key}, deferring Onyx write`);
    return;
    }

    reportAttributes has fourteen dependencies, and one of them is the locale, whose connection only initializes once translations finish loading. On DEV that takes seconds, so the window is wide. I drove a cold boot on the local dev server and watched what falls into it:

    • Derived value for reportAttributes restored from disk at 1.94s, immediately followed by thirteen not all connections set for reportAttributes, deferring Onyx write. Nothing is added to the pending set, so no delta survives.
    • The ReconnectApp response applied its onyxData at 4.28s. Six more dependency callbacks were dropped right behind it, carrying that payload's report, report action and metadata writes.
    • All connections initialized for key: reportAttributes only at 11.03s, when translations loaded. Exactly one compute followed it, 3ms long.

    That single flush is the problem. It is the first one, so hasFlushedOnce is false and the engine cannot reconstruct any delta, and it hands the config sourceValues === undefined:

    } else {
    // Capture baselines for every collection dependency so the next flush can diff against them.
    for (let index = 0; index < totalConnections; index++) {
    if (OnyxKeys.isCollectionKey(dependencies[index])) {
    stagedBaselines.push([index, readCollectionDependency(index)]);
    }
    }

    reportAttributes reads that as "a dependency fired but nothing changed", sees a populated currentValue restored from disk, and returns it untouched:

    // Use incremental updates when currentValue is already populated and no full recompute is required.
    // If currentValue has no reports (fresh install or cleared storage), fall back to a full scan.
    const useIncrementalUpdates = !!currentValue?.reports && Object.keys(currentValue.reports).length > 0 && !needsFullRecompute;
    // if we already computed the report attributes and there is no new reports data, return the current value
    if ((useIncrementalUpdates && !sourceValues) || !reports) {
    return currentValue ?? {reports: {}, locale: null};
    }

    And the same flush stages the collection baselines. So the data that arrived during the window is now folded into the baseline: no future change will ever name those reports, and the disk value stands forever.

    I confirmed the consequence deterministically. Setting a report while the locale connection is still pending leaves it with no entry in the derived value at all:

      reportAttributes.reports = {
        "cached":   { reportName: "Cached Report" },
    - "arriving": { reportName: "Arriving Report" },
      }

    From there the three reported symptoms are the same defect seen from three angles. The header title is the derived name, and the skeleton gate is only !title, so a missing entry pins the report on infinite loading:

    const shouldUseGroupTitle = isGroupChat && (!!report?.reportName || !isMultipleParticipant);
    const isLoading = !report?.reportID || !title;

    A stale entry gives the wrong name, and a missing or stale entry on the parent is what silently removes the From "…" line, since getParentNavigationSubtitle is fed the parent's derived name:

    const derivedParentReportName = getReportNameFromNames(derivedNames, parentNavigationReport?.parentReportID);
    const derivedReportHeaderName = getReportNameFromNames(derivedNames, reportHeaderData?.reportID);
    const isReportHeaderDataArchived = useReportIsArchived(reportHeaderData?.reportID);
    const reportHeaderDataPolicy = usePolicy(reportHeaderData?.policyID);
    const {accountID: currentUserAccountID} = useCurrentUserPersonalDetails();
    // Use sorted display names for the title for group chats on native small screen widths
    const title = getReportName(reportHeaderData, derivedReportHeaderName);
    const subtitle = getChatRoomSubtitle(reportHeaderData, reportHeaderDataPolicy, conciergeReportID, translate, false, isReportHeaderDataArchived);
    // This is used to get the status badge for invoice report subtitle.
    const statusTextForInvoiceReport = isParentInvoiceAndIsChatThread
    ? getReportStatusTranslation({stateNum: reportHeaderData?.stateNum, statusNum: reportHeaderData?.statusNum, translate})
    : undefined;
    const statusColorForInvoiceReport = isParentInvoiceAndIsChatThread ? getReportStatusColorStyle(theme, reportHeaderData?.stateNum, reportHeaderData?.statusNum) : {};
    const statusTooltipForInvoiceReport = isParentInvoiceAndIsChatThread
    ? getReportStatusTooltipTranslation({stateNum: reportHeaderData?.stateNum, statusNum: reportHeaderData?.statusNum, translate})
    : undefined;
    const isParentReportHeaderDataArchived = useReportIsArchived(reportHeaderData?.parentReportID);
    const parentNavigationSubtitleData = getParentNavigationSubtitle(parentNavigationReport, policy, conciergeReportID, translate, derivedParentReportName, isParentReportHeaderDataArchived);

    Why it shows up on DEV and not in production is ordering, not corruption. The disk value is well-formed and the right shape; it is simply never reconciled. On a production build the bundle and the translations chunk are ready long before the startup response, so the payload arrives after the connections are set and the normal incremental path handles it. On DEV the module graph and the locale chunk are slow, the API is not, and the payload lands inside the window instead.

    sequenceDiagram
        autonumber
        participant S as Server
        participant O as Onyx
        participant E as DerivedEngine
        E->>O: restore reportAttributes from disk at 1.94s
        O-->>E: 13 dependency callbacks, all deferred
        S-->>O: ReconnectApp onyxData at 4.28s
        O-->>E: 6 more callbacks, all deferred
        Note over E: nothing recorded, pendingDependencyIndexes stays empty
        E->>E: translations load, last connection set at 11.03s
        E->>O: first flush, sourceValues undefined, writes the disk value back
        Note over O: report present, reportAttributes entry absent, title empty
    
    Loading

    What changes do you think we should make in order to solve the problem?

    The engine knows something the config cannot infer: the first flush is the only one with no delta baselines, so "no source values" there means "I have no idea what changed", not "nothing changed". I would surface that on the compute context and let reportAttributes reconcile once against the complete dependency snapshots.

    In src/libs/actions/OnyxDerived/index.ts and types.ts, mark the flush; in src/libs/actions/OnyxDerived/configs/reportAttributes.ts, fold it into the existing needsFullRecompute so useIncrementalUpdates turns off for that one pass:

       context.triggeredKeys = triggeredKeys;
    +  context.isFirstFlush = !hasFlushedOnce;
       const needsFullRecompute =
    +      isFirstFlush ||
           (hasKeyTriggeredCompute(ONYXKEYS.NVP_PREFERRED_LOCALE, triggeredKeys) && preferredLocale !== currentValue?.locale) ||

    The reduce already seeds from currentValue.reports, so this is a merge, not a wipe: reports that were correct keep their entries, missing ones get built, stale ones get rebuilt. resetForClear sets hasFlushedOnce back to false, so the flush after an Onyx.clear() reconciles the same way, which is what that reset already wants.

    I verified both ends. A regression test that sets a report while the locale connection is still pending fails on current main with reportAttributes.reports.arriving === undefined and passes with this change, and the 65 tests in OnyxDerivedTest, OnyxDerivedSelfHealTest and reportAttributesTest stay green. In the browser I re-ran the same cold boot afterwards: the boot compute goes from 3ms to 22ms across 247 reports and the app renders normally, so the cost is one full scan per cold start, over data already in memory, which is what a fresh install does today anyway.

    This does not touch the guard the deferral was added for. No derived value is written while dependencies are incomplete, and every later flush keeps its current incremental behaviour.

    What alternative solutions did you explore? (Optional)

    Passing context.currentValue = undefined on the first flush is a one-liner in the engine and fixes all nine persisted derived values at once, but it forces a full recompute on every one of them at startup, which is a much larger blast radius on the exact path the startup telemetry spans in this file are watching. I would rather fix the reported flow and let the other configs opt in.

    I also looked at capturing the delta baselines when each connection initializes rather than at the first flush, which would keep the incremental path and cost almost nothing. I dropped it because it assumes the persisted derived value is in sync with the persisted dependency data, and those two writes are not atomic. A tab killed between them, which is routine on DEV, would leave the stale value in place with no way back. The full reconcile self-heals instead.

    Invalidating the persisted value on a version or schema stamp does not fit what I observed. The restored value was correctly shaped and internally consistent; it was discarded work, not bad data, so a stamp would not have flagged it.

  9. 58 remaining items

  10. melvin-bot commented on Sep 9, 2026

    @melvin-bot

    @thesahindia 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

  11. frontforge01 commented on Sep 11, 2026

    @frontforge01

    Proposal

    What is the root cause of that problem?

    It is not reproducible today on a normal machine because the window that causes it is about 50 ms wide. It becomes a real bug when that window gets wider.

    On startup OnyxDerived restores reportAttributes from disk, then waits for every dependency connection. Until the last one is set, each callback returns before it is recorded:

    const recomputeDerivedValue = (triggeredByIndex: number) => {
    // If this recompute was triggered by a connection callback, check if it initializes the connection.
    if (!areAllConnectionsSet) {
    checkAndMarkConnectionInitialized(triggeredByIndex);
    }
    // Before all connections are established, don't write to Onyx.
    // This prevents overwriting a valid disk-cached value with empty defaults,
    // and avoids N-1 unnecessary Onyx writes during initialization.
    // We still update dependencyValues via setDependencyValue so data accumulates correctly.
    if (!areAllConnectionsSet) {
    Log.info(`[OnyxDerived] not all connections set for ${key}, deferring Onyx write`);
    return;
    }

    The last connection is the locale, which only counts once the translations chunk has loaded:

    } else if (dependencyOnyxKey === ONYXKEYS.NVP_PREFERRED_LOCALE) {
    // Special case for locale, we want to recompute derived values when the locale change actually loads.
    Onyx.connectWithoutView({
    key: ONYXKEYS.RAM_ONLY_ARE_TRANSLATIONS_LOADING,
    callback: (value) => {
    if (value ?? true) {
    Log.info(`[OnyxDerived] translations are still loading, not recomputing derived value for ${key}`);
    return;
    }

    NavigationRoot (and so AuthScreens, which sends ReconnectApp) does not wait for translations, so server data can arrive inside that window:

    App/src/Expensify.tsx

    Lines 309 to 316 in 4302279

    {hasAttemptedToOpenPublicRoom && (CONFIG.IS_HYBRID_APP || initialUrl !== undefined) && (
    <NavigationRoot
    onReady={setNavigationReady}
    authenticated={isAuthenticated}
    lastVisitedPath={lastVisitedPath as Route}
    initialUrl={initialUrl ?? null}
    />
    )}

    The first flush then runs with sourceValues === undefined, which the engine means as "compute from scratch", and it stages the current collections as the baselines for every later diff:

    } else {
    // Capture baselines for every collection dependency so the next flush can diff against them.
    for (let index = 0; index < totalConnections; index++) {
    if (OnyxKeys.isCollectionKey(dependencies[index])) {
    stagedBaselines.push([index, readCollectionDependency(index)]);
    }
    }
    }

    reportAttributes reads the same signal as "nothing changed" and returns the restored value untouched:

    // Use incremental updates when currentValue is already populated and no full recompute is required.
    // If currentValue has no reports (fresh install or cleared storage), fall back to a full scan.
    const useIncrementalUpdates = !!currentValue?.reports && Object.keys(currentValue.reports).length > 0 && !needsFullRecompute;
    // if we already computed the report attributes and there is no new reports data, return the current value
    if ((useIncrementalUpdates && !sourceValues) || !reports) {
    return currentValue ?? {reports: {}, locale: null};
    }

    So whatever arrived in the window is now in the baseline and never produces a delta. The report keeps its old entry, or none, until something writes that report again.

    I reproduced this against the production backend with no code changes. The only change was the English translations chunk (src_languages_en_ts.bundle.js) delayed by 6 s with a Playwright route. On this machine it normally loads in 43 ms, or 72 ms with the cache disabled, and All connections initialized then lands before ReconnectApp is even sent. That is why the QA retest finds nothing. The steps:

    1. Web: create a task, comment on it, Reply in thread. The thread shows From 96718 task parent. Close the tab.
    2. Second device, same account: rename the task.
    3. Web: reopen the app while the translations chunk is slow, and open the thread.

    ReconnectApp finished at 2.56 s and OpenReport at 3.14 s, and the window only closed at 7.19 s. Onyx then held report_<task>.reportName: "96718 task parent RENAMED" but reportAttributes.reports[<task>].reportName: "96718 task parent", and the header showed From 96718 task parent. A second rename run survived a normal reload. A report created in Classic while the tab was closed got report_ but no reportAttributes entry at all (44 entries for 45 reports).

    That covers all three symptoms. The title falls back to the raw reportName (IOU, Chat Report, or ''), and an empty title keeps the skeleton up:

    function getReportName(report?: Report, derivedReportName?: string): string {
    if (!report?.reportID) {
    return '';
    }
    return derivedReportName ?? report.reportName ?? '';
    }

    The subtitle is hidden when the parent's derived name is empty, and wrong when it is stale:

    // We should not display the parent navigation subtitle if the user does not have access to the parent chat (the reportName is empty in this case)
    if (!reportName) {
    return;
    }

    It also explains why the bug looks intermittent. Opening a report usually heals that report, because OpenReport writes it (I saw this twice). Parents, LHN rows and reports you have not opened stay wrong.

    History: the deferral came with #82161 (Feb 2026), and the early return with 18f99e08c398 (2026-03-06). #95287 (relanded 2026-07-16) then made the first flush pass undefined on purpose to mean "from scratch", and reportAttributes never picked up that contract. The tests miss it because the engine suite marks translations loaded before any data is set, so no window ever exists:

    beforeEach(async () => {
    await Onyx.set(ONYXKEYS.RAM_ONLY_ARE_TRANSLATIONS_LOADING, false);
    await waitForBatchedUpdates();

    In addition, reportAttributesTest never calls compute with a restored value and no sourceValues.

    What changes do you think we should make in order to solve the problem?

    Only take the incremental path when there is a delta to apply. The first operand of the early return then can never be true, so I would drop it rather than leave a dead check:

    -        const useIncrementalUpdates = !!currentValue?.reports && Object.keys(currentValue.reports).length > 0 && !needsFullRecompute;
    +        const useIncrementalUpdates = !!currentValue?.reports && Object.keys(currentValue.reports).length > 0 && !needsFullRecompute && !!sourceValues;
     ...
    -        if ((useIncrementalUpdates && !sourceValues) || !reports) {
    +        if (!reports) {

    The first flush then runs a full scan against the complete snapshots, seeded from currentValue.reports, which are the same snapshots the engine is about to store as baselines. This one condition does both jobs. New users no longer enter the state, and a device that already holds a stale value rebuilds it on its next boot.

    With the change above, the same steps show From 96718 task parent R3. ReconnectApp and OpenReport still land inside the window, and the first compute takes 4 ms. A task created while the tab was closed gets its entry (49 reports, 49 entries). A normal boot on the stale state the BEFORE run left behind rebuilt it to the current title (7 ms for 48 reports). Stashing the patch brings the symptom back: the same steps leave the derived name one rename behind, and the thread shows From 96718 task parent R3 while the task is R4.

    Regression safety:

    • reportAttributes is the only persisted config that combines a restored currentValue with a no-delta early return. reportTransactionsAndViolations and visibleReportActions already rebuild when there is no delta, and sortedReportActions is RAM-only. That is read from code.
    • Steady state is unchanged. On one boot followed by a comment, Force offline on and off, Spend and a chat, the only compute without sourceValues was the first flush. Every later compute carried a delta and stayed incremental.
    • The deferral guard is untouched, so nothing is written while dependencies are incomplete.
    • compute is only called by the engine and writes only its own key, so the full scan cannot re-trigger itself.

    One thing I want to be straight about: because the scan is seeded from currentValue, an entry for a report deleted while the app was closed survives. That is what happens today too, and no screen renders it without the report.

    Test: in reportAttributesTest.ts, a restored value holding Stale Name with sourceValues: undefined and a locale trigger. On current main it fails with Expected: "Test Report", Received: "Stale Name"; with the change it passes. 127/127 across the 13 derived-value suites, and lint and format are clean.

    What alternative solutions did you explore? (Optional)

    • An isFirstFlush flag on the context. It gives the same result. On the session I watched, sourceValues was only missing on the first flush, so the flag adds an engine and type change to express a signal the config already receives.
    • Dropping currentValue for every config on the first flush. This also removes orphan entries, but it throws away the seed that computeReportName reads for moved-expense thread names. It also changes a contract the other configs do not need changed, since they already rebuild.
    • Recording the deltas that arrive during the window. This keeps the restored value as the base and assumes it matches the persisted reports. Here it did not: the stale value survived a normal reload.
    • Patching HeaderView or ParentNavigationSubtitle. They render the stored value faithfully; the value itself is stale in Onyx.
  12. melvin-bot commented on Sep 11, 2026

    @melvin-bot

    📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

  13. melvin-bot commented on Sep 11, 2026

    @melvin-bot

    @thesahindia Now this issue is 8 days overdue. Are you sure this should be a Daily? Feel free to change it!

  14. melvin-bot commented on Sep 15, 2026

    @melvin-bot

    @thesahindia 12 days overdue. Walking. Toward. The. Light...

  15. eswar5678 commented on Sep 16, 2026

    @eswar5678
  16. melvin-bot commented on Sep 16, 2026

    @melvin-bot

    📣 @eswar5678! 📣
    Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
    Please follow these steps:

    1. Make sure you've read and understood the contributing guidelines.
    2. Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
    3. Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
    4. Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details.
      Screen Shot 2022-11-16 at 4 42 54 PM
      Format:
    Contributor details
    Your Expensify account email: <REPLACE EMAIL HERE>
    Upwork Profile Link: <REPLACE LINK HERE>
    
  17. github-actions commented on Sep 16, 2026

    @github-actions
    Contributor

    ⚠️ @eswar5678 Thanks for your interest. To be considered for this job, please post a proposal following the proposal template (note the mandatory sections). Comments claiming the job without one are not reviewed.

  18. melvin-bot commented on Sep 18, 2026

    @melvin-bot

    📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

  19. melvin-bot commented on Sep 18, 2026

    @melvin-bot

    This issue has not been updated in over 14 days. @thesahindia eroding to Weekly issue.

  20. roryabraham commented on Sep 19, 2026

    @roryabraham
    Contributor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

BugSomething is broken. Auto assigns a BugZero manager.ExternalAdded to denote the issue can be worked on by a contributorHelp WantedApply this label when an issue is open to proposals by contributorsWeeklyKSv2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions