Skip to content

Keep the mixnet across a send retry on another server - #1917

Open
juanky201271 wants to merge 1 commit into
devfrom
fix/send-retry-keeps-mixnet
Open

juanky201271 wants to merge 1 commit into
devfrom
fix/send-retry-keeps-mixnet

Conversation

@juanky201271

Copy link
Copy Markdown
Contributor

Beta 346 (Android): a send failed with the Nym mixnet is not enabled while the header read ready.

Cause. The first attempt failed on DNS, and settleSend retried on another server through setServerOption. That reopens the wallet (loadExistingWallet → init_from_bytes), which creates a new zingolib client in Unattached. configure() didn't re-arm the mixnet because mixnetOnline was already true, so the retry was refused. The header kept showing ready until the next 30 s poll.

Fix

  • The send retry moves the open wallet with changeServer (new switchServerForRetry), the same path recoverServer uses, so the client keeps its mixnet. The dial and persist steps are shared with activateReachableServer (moveToServer).
  • setServerOption (Settings) calls walletReopened() after reopening the wallet, which re-arms the mixnet for the new client.

Tests

  • The Send retry test expects switchServerForRetry.
  • Connectivity suite: a reopened wallet re-arms the mixnet; an Offline one stays off.

Not covered here: when init_from_bytes fails it has already dropped the old client, so setServerOption's fallback changeServer(old) has no client to act on.

🤖 Generated with Claude Code

The send retry switched servers through setServerOption, which reopens
the wallet: a new zingolib client, born Unattached. configure() did not
re-arm the mixnet because the session already counted as armed, so the
retried send refused with "the Nym mixnet is not enabled" while the
header still read ready until the next 30 s poll (Beta 346 report).

- The retry now moves the open wallet with changeServer, the same path
  the runtime server recovery uses, so the client keeps its mixnet.
- setServerOption re-arms the mixnet after reopening the wallet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

Visual review — ✅ matches baseline

Head vs visual/__baseline__. Open the review page — Current, Animations, and Image diffs tabs.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant