Skip to content

[Today] TomorrowNote is stored/fetched same-day - the 'tomorrow' hand-off its UI copy and controller doc promise never happens; OAuthAuthCode.UserId summary contradicts CreateForLinking #1640

Description

@Chris0Jeky

Found during the PR #1629 DATA_MODEL.md recertification (round-2 review). Two related defects on the TomorrowNote / OAuthAuthCode surface; both are code-vs-contract mismatches, not just doc drift.

1. TomorrowNote "tomorrow" feature never shows a note to the tomorrow-self

Traced end to end at #1629's head:

  • Save key: formatLocalDossierDate(dossier.value.date) (PaperTodayView.vue:50:save-dateTodayLineForTomorrow.vue:72).
  • Read key: todayApi.getTomorrowNote(formatLocalDossierDate(now.value)) (useTodayDossier.ts:374,381).
  • Neither TomorrowNoteService nor TodayController applies AddDays(1).

So a note written on day X is stored under key X and fetched on day X; at rollover useTodayDossier.ts:408 clears the field and day X+1 queries key X+1 → 204. The note is never surfaced to the "tomorrow" self, contradicting both the UI copy and TodayController.GetTomorrowNote's XML doc, which promise an X→X+1 hand-off.

Decide the intended contract: either make save/read do the one-day shift (feature as advertised), or relabel it a same-day scratch note and fix the UI copy + controller doc. DATA_MODEL.md now documents the shipped same-day behavior with the intent gap noted.

2. OAuthAuthCode.UserId XML summary contradicts CreateForLinking

OAuthAuthCode.UserId's XML summary says the value may be Guid.Empty for the link flow, but CreateForLinking (OAuthAuthCode.cs:100-101) rejects Guid.Empty. Reword the summary to match (both flows require a non-empty user id — the binding is load-bearing, enforced at AuthController.cs:437).

Refs PR #1629, #1470.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Priority IIThe active direction's next tranche: wedge capabilities, significant defects, near-term hardening.backendPrimary implementation impact in .NET API/domain/application/infrastructure.bugSomething isn't workingfrontendPrimary implementation impact in Vue/TypeScript UI and client runtime.

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions