Repository navigation
Add remote-aware resume bindings for SSH workspaces #8441
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
Merged
Merged
Changes from 2 commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
1d094c8
test: cover remote SSH resume bindings
cd31bb2
feat: add remote-aware SSH resume bindings
50e2370
fix: authenticate remote resume relay provenance
aa7e0cc
fix: compile relay provenance authentication
35ab5de
fix: address remote resume review findings
dd629a6
refactor: satisfy remote resume file policy
7a19f20
test: cover legacy remote resume migration
0f6324d
fix: migrate legacy remote resume bindings
536f17a
test: cover workspace-id-free legacy resume
81f5f5f
fix: recover legacy remote workspace identity
1bb3105
test: remove unused remote resume helper inputs
9e6e880
test: cover resume with unsupported remote shell
c2ecafc
test: import remote configuration module
f9ad1a6
test: disambiguate resume command decoding
a5e338a
fix: resume before unsupported remote shells
ca90da2
test: cover escaped remote resume method
8b95fa2
fix: preserve unsupported remote login shells
38585b7
fix: classify relayed resume methods structurally
004d8de
test: remove unnecessary remote resume throws
83b67ee
Merge remote-tracking branch 'origin/main' into issue-7989-remote-res…
91fa5f7
Merge remote-tracking branch 'origin/main' into issue-7989-remote-res…
6bddf9d
Merge remote-tracking branch 'origin/main' into issue-7989-remote-res…
5af83f7
fix: integrate remote resume bootstrap API
1b9603c
test: fix merged remote transport coverage
4c6f88c
test: fix remote prompt diagnostics
3888079
fix: run resume before unsupported remote shells
4e6fc46
Merge origin/main into issue-7989-remote-resume-bindings
6bd4b32
Expand remote resume verification coverage
fefcb08
Fix remote resume verifier assertions
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| import Foundation | ||
|
|
||
| extension SurfaceResumeBindingSnapshot { | ||
| func registeredForPersistentSSH(_ context: SurfaceResumeRemoteContext) -> SurfaceResumeBindingSnapshot { | ||
| replacingLaunchFlavor(.persistentSSH(context)) | ||
| } | ||
|
|
||
| func retargetingRemoteOwner( | ||
| expectedWorkspaceID: UUID, | ||
| expectedSurfaceID: UUID, | ||
| workspaceID: UUID, | ||
| surfaceID: UUID, | ||
| persistentPTYSessionID: String? | ||
| ) -> SurfaceResumeBindingSnapshot { | ||
| guard case .persistentSSH(let context) = launchFlavor, | ||
| let persistentPTYSessionID, | ||
| context.matches( | ||
| workspaceID: expectedWorkspaceID, | ||
| surfaceID: expectedSurfaceID, | ||
| persistentPTYSessionID: persistentPTYSessionID | ||
| ) else { | ||
| return self | ||
| } | ||
| return replacingLaunchFlavor(.persistentSSH(context.retargeted( | ||
| workspaceID: workspaceID, | ||
| surfaceID: surfaceID, | ||
| persistentPTYSessionID: persistentPTYSessionID | ||
| ))) | ||
| } | ||
|
|
||
| private func replacingLaunchFlavor( | ||
| _ launchFlavor: SurfaceResumeLaunchFlavor | ||
| ) -> SurfaceResumeBindingSnapshot { | ||
| SurfaceResumeBindingSnapshot( | ||
| name: name, | ||
| kind: kind, | ||
| command: command, | ||
| cwd: cwd, | ||
| checkpointId: checkpointId, | ||
| source: source, | ||
| environment: environment, | ||
| autoResume: autoResume, | ||
| approvalPolicy: approvalPolicy, | ||
| approvalRecordId: approvalRecordId, | ||
| launchFlavor: launchFlavor, | ||
| updatedAt: updatedAt | ||
| ) | ||
| } | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.