-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Set session socket into environment variable #6282
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
Conversation
d29217c
to
def0807
Compare
Going to add an e2e test as well since I think we can do that fairly easily. |
def0807
to
91b9e62
Compare
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #6282 +/- ##
==========================================
+ Coverage 73.59% 73.67% +0.08%
==========================================
Files 31 31
Lines 1863 1869 +6
Branches 399 401 +2
==========================================
+ Hits 1371 1377 +6
Misses 415 415
Partials 77 77
Continue to review full report in Codecov by Sentry.
|
9884812
to
38107f3
Compare
These flags mean the user explicitly wants to open in an existing instance so if the socket is down it should error rather than try to spawn code-server normally.
While I was at it I added a CLI flag to override the default. I also swapped the default to --user-data-dir. The value is set on an environment variable so it can be used by the extension host similar to VSCODE_IPC_HOOK_CLI.
38107f3
to
c56b194
Compare
@code-asher FYI Release v4.14.1-rc.1 (which does not include this change) work just fine. |
Thank you! I will make one more RC so I can make a new release with this bugfix. |
@sleexyz just a ping in case you wanted to check this over. Apologies for unilaterally continuing the fix; I was a bit anxious to finish it because I had just released the RC with our partial fix and I figured we should add an e2e test and did not want to saddle you with that (the e2e scaffolding can be difficult to work with). Please let me know if anything looks dumb. Going to merge for now so I can start the next RC tonight but if something needs to be fixed we can always do another RC. |
Looks great! Thanks for the heads up, and sorry for the oversight 😅 |
* Avoid spawning code-server with --reuse-window and --new-window These flags mean the user explicitly wants to open in an existing instance so if the socket is down it should error rather than try to spawn code-server normally. * Set session socket into environment variable While I was at it I added a CLI flag to override the default. I also swapped the default to --user-data-dir. The value is set on an environment variable so it can be used by the extension host similar to VSCODE_IPC_HOOK_CLI. * Add e2e test for opening files externally
While I was at it I added a CLI flag to override the default. I also swapped the default to --user-data-dir.
The value is set on an environment variable so it can be used by the extension host similar to VSCODE_IPC_HOOK_CLI.
Continuation of #6278 for #6275. We changed the socket path but did not propagate that change down to VS Code yet. The environment variable takes care of that.