Repository navigation
Start cached IROH connection before startup backup refresh #15345
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
7814fd2
4f6f58b
d8a9c75
16cd25d
12ef215
93d0db5
c9a6b58
792a561
73bc8cf
6372c0c
1ece6fc
0cf1b27
9fac2b6
5c504e8
5901f7d
a396428
b980721
582713d
c146010
27c401b
814ebe7
73bd646
2b64a40
0ba4041
2bbb2ef
fa8f1c1
6a17189
1e87a6e
241ba19
db62464
1a91f7c
f7db0fa
bf90a77
4fe8ac5
5aeab39
99ca1d8
8bc596e
61a88a2
a93af42
4f7f4b5
cb9d421
5696ef1
41659c1
14dc577
eb1aa35
451933a
c84fb67
c5cb772
f3928a3
9574395
5f67eea
45f19d0
185be6c
908e2ee
76178d0
02bb470
849ed89
e52cb3e
35c7723
5bd6005
c7cb704
01b0f64
2359026
5afde77
9ecd5aa
b934ccf
1db5b80
8c4cfb5
1c10a44
a06061a
59cbda2
82618ef
4cbdeea
6c9f137
07b9624
c5a9d15
a11fc3c
c3b97e1
beadd57
d9724bc
27fba71
1887e53
1ce9bc8
344cac1
5c5388e
2f5c012
6b68c8c
07f7c13
7ea8285
0583749
b1f7a18
4c78ecf
08c8047
6985f9e
1b444a0
00959bf
b834f86
a34c7ee
5386126
2fa7297
f06f502
40aa04e
c589ff8
c5caca7
97e5a7f
859ca92
b908dde
2ca91b5
f66904b
c21b0a8
825e0d3
5ea8219
2c33e92
538aaf6
4b7b837
0117647
94acff9
5955b67
0d2b312
eba8488
f59f37d
2f574d6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -40,7 +40,6 @@ on: | |
| options: | ||
| - basic | ||
| - stress | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
|
|
@@ -256,6 +255,10 @@ jobs: | |
| # reload's standalone-driver shortcut fails while merging opaque SwiftUI | ||
| # return types on Xcode 26.3 before either endpoint can launch. | ||
| CMUX_RELOAD_APP_EMIT_MODULE: "1" | ||
| # The release gate exercises IROH and does not need the optional Ghostty | ||
| # CLI helper. Avoid an unrelated network fetch from Ghostty's Zig build | ||
| # turning a transport verdict into a runner TLS failure. | ||
| CMUX_SKIP_ZIG_BUILD: "1" | ||
| strategy: | ||
| fail-fast: false | ||
| # The app-backed modes share one temporary account per environment. | ||
|
|
@@ -265,7 +268,11 @@ jobs: | |
| matrix: | ||
| mode: ${{ fromJSON(inputs.mode == 'all' && '["automatic","relay-only","relay-expiry","direct-only","private-path"]' || format('["{0}"]', inputs.mode)) }} | ||
| runs-on: ${{ github.repository_owner != 'manaflow-ai' && 'macos-26' || (vars.CI_PAID_MACOS_OVERFLOW == '1' && vars.MACOS_RUNNER_15 || 'blacksmith-6vcpu-macos-15') }} | ||
| timeout-minutes: 120 | ||
| # The real relay rollover probe waits through the 30-minute credential | ||
| # lifetime after the one-hour workload. Keep enough room for the hosted | ||
| # build, simulator setup, artifact upload, and runner cleanup so a passing | ||
| # report is not converted into a cancelled job at the hard deadline. | ||
| timeout-minutes: 180 | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | ||
|
|
@@ -294,6 +301,17 @@ jobs: | |
| with: | ||
| bun-version: "1.4.2" | ||
|
|
||
| - name: Install AXe simulator driver | ||
| if: ${{ matrix.mode == 'automatic' || matrix.mode == 'relay-only' || matrix.mode == 'relay-expiry' }} | ||
| run: | | ||
| set -euo pipefail | ||
| # ios-e2e-run.sh uses AXe for accessibility and HID input. Hosted | ||
| # runners do not guarantee it in PATH, so install the maintained | ||
| # Homebrew formula explicitly before any simulator interaction. | ||
| brew install cameroncooke/axe/axe | ||
| command -v axe | ||
| axe --version | ||
|
|
||
| - name: Install web runtime dependencies | ||
| if: ${{ matrix.mode == 'automatic' || matrix.mode == 'relay-only' || matrix.mode == 'relay-expiry' }} | ||
| working-directory: web | ||
|
|
@@ -390,6 +408,9 @@ jobs: | |
| if [[ "${{ matrix.mode }}" == automatic || "${{ matrix.mode }}" == relay-only ]]; then | ||
| GATE_ARGS+=(--soak-profile "${{ inputs.soak_profile }}") | ||
| fi | ||
| if [[ "${{ inputs.environment }}" == production && "${{ matrix.mode }}" == relay-only && "${{ inputs.soak_profile }}" == stress ]]; then | ||
| GATE_ARGS+=(--real-usage) | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P1: Prompt for AI agents
cubic-dev-ai[bot] marked this conversation as resolved.
Resolved
|
||
| fi | ||
| ./scripts/run-iroh-release-gate.sh "${GATE_ARGS[@]}" | ||
|
|
||
| - name: Upload redacted verdict | ||
|
|
@@ -402,7 +423,10 @@ jobs: | |
| ${{ runner.temp }}/iroh-release-gate-${{ matrix.mode }}-mac.cmuxdiag | ||
| ${{ runner.temp }}/iroh-release-gate-${{ matrix.mode }}-ios-failure.log | ||
| ${{ runner.temp }}/iroh-release-gate-${{ matrix.mode }}-ios-failure.png | ||
| ${{ runner.temp }}/iroh-release-gate-${{ matrix.mode }}-ios-*.jsonl | ||
| ${{ runner.temp }}/iroh-release-gate-${{ matrix.mode }}-ios-*.log | ||
| ${{ runner.temp }}/iroh-release-gate-${{ matrix.mode }}-mac-failure.cmuxdiag | ||
| ${{ runner.temp }}/iroh-release-gate-${{ matrix.mode }}-real-usage/** | ||
| if-no-files-found: warn | ||
| retention-days: 7 | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -30774,7 +30774,7 @@ struct CMUXCLI { | |
| candidate = failure | ||
| candidateCanPublishBeforeTerminal = turnId == nil || payloadTurnId == turnId || sawRelevantTurn | ||
| } | ||
| case "task_complete", "turn_complete": | ||
| case "task_complete", "turn_complete", "turn_aborted": | ||
| let payloadTurnId = firstString(in: payload, keys: ["turn_id", "turnId"]) | ||
| if let turnId { | ||
| guard payloadTurnId == turnId else { | ||
|
|
@@ -30783,6 +30783,12 @@ struct CMUXCLI { | |
| } | ||
| sawRelevantTurn = true | ||
| sawTerminalTurn = true | ||
| // An interrupted turn is still terminal for the monitor. It | ||
| // has no final response to classify as a failure, so let the | ||
| // normal Stop replay retire its stale prompt record. | ||
| if eventType == "turn_aborted" { | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P1: An aborted turn can still publish a stale error from an earlier Prompt for AI agents |
||
| continue | ||
| } | ||
| // Codex persists fatal turn failures inside task_complete.error. Standalone | ||
| // error events are transient, and a failed turn may still contain partial | ||
| // assistant output, so the terminal error must be authoritative. | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -321,12 +321,17 @@ public struct MobileSyncWorkspaceListResponse: Decodable, Sendable { | |||||
| public let createdWorkspaceID: String? | ||||||
| /// Identifier of a terminal created by the request, if any. | ||||||
| public let createdTerminalID: String? | ||||||
| /// Authenticated host metadata returned by the v2 mobile workspace-list | ||||||
| /// method. Older Macs omit this field and the caller falls back to the | ||||||
| /// separate host-status request. | ||||||
| public let hostStatus: MobileHostStatusResponse? | ||||||
|
|
||||||
| private enum CodingKeys: String, CodingKey { | ||||||
| case workspaces | ||||||
| case groups | ||||||
| case createdWorkspaceID = "created_workspace_id" | ||||||
| case createdTerminalID = "created_terminal_id" | ||||||
| case hostStatus = "host_status" | ||||||
| } | ||||||
|
|
||||||
| /// Decodes a workspace-list response, defaulting `groups` to empty so a Mac | ||||||
|
|
@@ -341,6 +346,7 @@ public struct MobileSyncWorkspaceListResponse: Decodable, Sendable { | |||||
| groups = try container.decodeIfPresent([Group].self, forKey: .groups) ?? [] | ||||||
| createdWorkspaceID = try container.decodeIfPresent(String.self, forKey: .createdWorkspaceID) | ||||||
| createdTerminalID = try container.decodeIfPresent(String.self, forKey: .createdTerminalID) | ||||||
| hostStatus = try container.decodeIfPresent(MobileHostStatusResponse.self, forKey: .hostStatus) | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P2: Prompt for AI agents
Suggested change
|
||||||
| } | ||||||
|
|
||||||
| /// Decode a workspace-list response from raw JSON data. | ||||||
|
|
@@ -363,12 +369,14 @@ extension MobileSyncWorkspaceListResponse { | |||||
| groups: [Group], | ||||||
| groupsFieldWasPresent: Bool = true, | ||||||
| createdWorkspaceID: String?, | ||||||
| createdTerminalID: String? | ||||||
| createdTerminalID: String?, | ||||||
| hostStatus: MobileHostStatusResponse? = nil | ||||||
| ) { | ||||||
| self.workspaces = workspaces | ||||||
| self.groups = groups | ||||||
| self.groupsFieldWasPresent = groupsFieldWasPresent | ||||||
| self.createdWorkspaceID = createdWorkspaceID | ||||||
| self.createdTerminalID = createdTerminalID | ||||||
| self.hostStatus = hostStatus | ||||||
| } | ||||||
| } | ||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -31,6 +31,26 @@ extension MobileShellComposite { | |
| return scoped.union(userWide) | ||
| } | ||
|
|
||
| /// Matches a stored hidden marker to a typed app-instance key. Older | ||
| /// markers can use a raw device id or preserve different casing, so a | ||
| /// string lookup is not sufficient for cached snapshot restoration. | ||
| /// A raw marker remains scoped to the legacy untagged pairing; a tagged | ||
| /// marker matches only the same tagged app instance. | ||
| func isHiddenMacPairingKey( | ||
| _ key: MacPairingKey, | ||
| hiddenIDs: Set<String> | ||
| ) -> Bool { | ||
| let expectedDeviceID = cmxCanonicalDeviceID(key.canonicalMacDeviceID).lowercased() | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P2: The lowercasing makes isHiddenMacPairingKey treat a case-differing legacy marker as hidden, but the other hidden-state checks in this file — visibleStoredPairedMacs and isHiddenMacDeviceID — still compare raw markers with exact string membership, and cmxCanonicalDeviceID only lowercases UUIDs (non-UUID IDs are returned byte-for-byte). So for a marker like "MAC-A" against a row key "mac-a", restoreWorkspaceSnapshots now suppresses the cached workspace while the row stays visible in the list and routing still treats the Mac as unhidden. Apply the same case-insensitive canonical comparison in isHiddenMacDeviceID and visibleStoredPairedMacs (handling both bare device markers and composite pairing IDs) so the three checks agree, or the hide state is only half-applied. Prompt for AI agents |
||
| let expectedTag = macInstanceTagAuthority.normalize(key.normalizedInstanceTag)?.lowercased() | ||
| return hiddenIDs.contains { marker in | ||
| let identity = MobilePairedMac.pairingIdentity(from: marker) | ||
| guard cmxCanonicalDeviceID(identity.macDeviceID).lowercased() == expectedDeviceID else { | ||
| return false | ||
| } | ||
| return macInstanceTagAuthority.normalize(identity.instanceTag)?.lowercased() == expectedTag | ||
| } | ||
| } | ||
|
|
||
| func visibleStoredPairedMacs( | ||
| from loadedMacs: [MobilePairedMac], | ||
| scope: MobileShellScopeSnapshot | ||
|
|
@@ -428,6 +448,38 @@ extension MobileShellComposite { | |
| // rowless and clear them, so the hidden entry the user retries from | ||
| // would vanish while a failed sibling keeps its revoked binding. | ||
| if deletion.cleaned { | ||
| if let workspaceSnapshotStore { | ||
| let snapshotAccountID = computer.stackUserID ?? scope.userID | ||
| let deletedScopes = deletion.deletedScopes.isEmpty | ||
| ? [MobilePairedMacExactScope( | ||
| macDeviceID: computer.macDeviceID, | ||
| instanceTag: computer.instanceTag, | ||
| stackUserID: snapshotAccountID, | ||
| teamID: computer.teamID | ||
| )] | ||
| : deletion.deletedScopes | ||
| for deletedScope in deletedScopes | ||
| where (deletedScope.stackUserID ?? snapshotAccountID) == snapshotAccountID { | ||
| // Legacy paired rows may not carry a team. Their workspace | ||
| // snapshot was written under the currently selected team, | ||
| // so clear that scoped key as well as the old team-less key. | ||
| var snapshotTeamIDs = [deletedScope.teamID] | ||
| if deletedScope.teamID == nil, let currentTeamID = scope.teamID { | ||
| snapshotTeamIDs.append(currentTeamID) | ||
| } | ||
| for snapshotTeamID in snapshotTeamIDs { | ||
| await workspaceSnapshotStore.remove( | ||
| userID: snapshotAccountID, | ||
| teamID: snapshotTeamID, | ||
| pairing: MacPairingKey( | ||
| macDeviceID: deletedScope.macDeviceID, | ||
| instanceTag: deletedScope.instanceTag | ||
| ), | ||
| force: true | ||
| ) | ||
| } | ||
| } | ||
| } | ||
| rememberForgottenMacRecovery( | ||
| for: computer, | ||
| accountID: scope.userID, | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
P2: This new run-step embeds workflow inputs directly into the generated shell script. Bind them through
env:and compare shell variables instead, so input values cannot alter shell parsing and the workflow follows the repository’s CI convention.(Based on your team's feedback about workflow input interpolation.)
View Feedback
Prompt for AI agents