Skip to content

bug: pubky sign-in sheet can disappear when a link cold-starts bitkit #957

Closed

Description

@ovitrif

Refs:

What happened?

On a cold start, Bitkit iOS can handle the same Pubky sign-in link twice. The second handling replaces the Authorize sheet that is already open, and the first sheet's dismiss handler then hides the replacement, so no Authorize sheet is left on screen and the sign-in stalls.

Seen in 1 of 3 cold starts while testing the Pubky App's "Authorize with Bitkit" link (pubky/pubky-app#2833) on an iPhone with only Bitkit installed. The link was handled at 11:39:03.76 and again at 11:39:04.11 CEST.

Code at eb3156a: MainNavView.swift:852, MainNavView.swift:428-456, MainNavView.swift:152, SheetViewModel.swift:52-58.

Expected behavior

A sign-in link that arrives once opens one Authorize sheet, and that sheet stays open until the user approves or declines, also on a cold start.

Steps to Reproduce

  1. Force-quit Bitkit on an iPhone with only Bitkit installed.
  2. On pubky.app (or the embedded Shop), choose "Authorize with Bitkit".
  3. Bitkit cold-starts; sometimes the Authorize sheet appears and then disappears.
  4. Tapping the link again with Bitkit running works.

Logs / Screenshots / Recordings

Screen recording available on request.

Bitkit Version

3.0.0 RC2 (current master, eb3156a)

Device / OS

iPhone, iOS 26

Reproducibility

Sometimes (1 of 3 cold starts)

Activity

  1. added this to the 3.0.5 milestone on Oct 16, 2026
  2. self-assigned this
    on Oct 16, 2026
  3. ovitrif commented on Oct 16, 2026

    @ovitrif
    CollaboratorAuthor

    Fixed in #966: a cold start delivered the link twice (onOpenURL and the scene delegate replay), and the startup gate routed the first before the second arrived. The repeat is now ignored, and a replaced sign-in sheet's dismiss can no longer hide the new one. Five simulator cold starts from the Shop staging link each kept one Authorize sheet open.

  4. modified the milestones: 3.0.5, 3.0.0 on Oct 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions