Skip to content

A refused diary session handover is reported as a wrong password #759

Closed

Description

@lumenpearson

Failure scenario

The phone successfully opens an upstream diary session, then CreateDiarySession receives DIARY_CREDENTIALS_REJECTED because the upstream rejects that already-good session from the server's address. DiarySignInProblem.ofRemote currently maps the structured reason to WrongPassword. The family sees «Неверный логин или пароль», and onboarding hides the class-code alternative. Asking for the password again repeats the wrong recovery path.

The approved proto explicitly says this reason means the session opened on the phone was refused from this server, and maps the old v1 session409 case. The server error adapter confirms it judges no password. Source a86f0ce, DiarySignInProblem.kt314, errors.proto91–93, SignInPage.kt273. The independent reviewer found this; the existing classifier expectation accepts the incorrect result. No new regression had run at filing.

Acceptance

  • Successful upstream login followed by structured registration refusal first reproduces the wrong classification/recovery action.
  • Registration refusal becomes ServerRefusedSession with the appropriate recovery action.
  • An actual upstream BadCredentials control still produces WrongPassword.
  • REST/Connect/gRPC structured reason handling, focused RED/GREEN, complete gates and delivery pass with Move the remaining Android remotes to v2 transports (stage 5b) #746.

Parent #746; independent whole-branch finding I1, single corrective pass. No password or real account is needed for the witness.

Corrective checkpoint — 14 November 2026

DiarySignInTest opens upstream successfully before DIARY_CREDENTIALS_REJECTED; DiarySignInRemainingFailureTest now expects ServerRefusedSession. The two wrong-classification assertions were observed before correction.

The actual upstream BadCredentials control still produces WrongPassword; all structured transport regressions pass in the full data985 set.

The ONE review corrective cohort first produced82 cases/20 AssertionError failures; the same82 identities now pass. Full unfiltered Android test/both ordinary assembles/detekt passed at2202 unique cases,0failures/errors/skips. Both completed-report count validators pass at3910/2202 and168 selected document guards pass separately. No baseline growth or suppression was added. Earlier failed/green evidence remains retained.

Corrective head is 473e88af87b5a106cee660a2c7fe24b7029fd0f9 in draft PR #757. Exact-head CI43554034696 is still running at this checkpoint. CI/dev/master delivery and the broader #746 acceptance remain unfinished; this issue stays open. No re-review is planned; Minor #764/#765 remain deferred.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    • Status
      Done

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions