Skip to content

fix: Fix macOS keychain prompt in latest Electron#1396

Merged
timfish merged 5 commits into
masterfrom
fix/credentials-prompt
Jul 1, 2026
Merged

fix: Fix macOS keychain prompt in latest Electron#1396
timfish merged 5 commits into
masterfrom
fix/credentials-prompt

Conversation

@timfish

@timfish timfish commented Jun 30, 2026

Copy link
Copy Markdown
Collaborator

There is no easy way to test this. Our CI test's didn't even pick up the issue.

@timfish timfish requested a review from nicohrubec June 30, 2026 11:38
@timfish timfish changed the title fix: Fix macOS keychain prompt fix: Fix macOS keychain prompt in latest Electron Jun 30, 2026
@timfish timfish enabled auto-merge (squash) June 30, 2026 11:39
Comment thread src/main/transports/electron-net.ts
timfish and others added 3 commits July 1, 2026 10:06
- Use a dynamic dispatcher in beforeEach so ignoreOrder is checked at
  event-receive time rather than server-creation time (before the test
  callback has had a chance to call ignoreExpectationOrder())
- Reset all mutable state at the start of the test body so vitest
  retries start clean instead of inheriting a rejected completePromise
- Add ignoreExpectationOrder() to browser-profiling-trace because
  profile_chunk arrives before transaction on Windows

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The previous impl passed function matchers into expect.arrayContaining()
which treats them as literal values (reference equality), so the check
always failed for tests like session-native-crash-main that use function
matchers to capture cross-event state (firstSessionId).

Replace with a greedy matching loop: for each received event (in arrival
order), find the first expectation that passes when called or toEqual'd.
Processing in arrival order preserves the dependency order for function
matchers that have side-effects (e.g. capturing a session ID in the
first handler and verifying it in a later one).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@timfish timfish merged commit 9d20f6e into master Jul 1, 2026
117 checks passed
@timfish timfish deleted the fix/credentials-prompt branch July 1, 2026 11:31
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.

Keychain access prompt appears when SDK is added

3 participants