-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
VS Code loading twice at workspace startup #21400
Comments
The work on this issue has been postponed. At least, until we fix #21537 |
We should try replacing |
@l0rd it's a good idea. But it works OOTB for Hardcoding That's why we have As I see it, one of the options for fixing that problem would be to move that logic from the extension to the entry point script. In that case we could provide the correct path to the server side instead of redirecting the client. |
|
So the proposal is to resolve For example, an endpoint with a path that references endpoints:
- name: che-code
attributes:
type: main
cookiesAuthEnabled: true
discoverable: false
urlRewriteSupported: true
targetPort: 3100
exposure: public
path: '?folder=${PROJECT_SOURCE}'
secure: false
protocol: https should result in a DevWorkspace status where the "status": {
(...)
"mainUrl": "https://workspace1bc9e32c0fcd4aed.apps.mloriedo-devworkspaces.devcluster.openshift.com/che-code/?folder=/projects/my-project",
"message": "https://workspace1bc9e32c0fcd4aed.apps.mloriedo-devworkspaces.devcluster.openshift.com/che-code/?folder=/projects/my-project",
"phase": "Running"
} I am adding the label |
That sounds great! As most of the workspaces are single-root projects, it should fix the problem for the vast majority of cases. |
I've found out how we can do the same in VS Code entrypoint. |
👍great! Let's do that then |
Fixed by che-incubator/che-code#131. |
This issue was not manually cloned into Jira for release notes because VS Code was a Technology Preview feature up until Che 7.56 / DS 3.4, and we don't document known issues or bug fixes for Technology Preview features in DS release notes. |
sync'd to Red Hat JIRA https://issues.redhat.com/browse/CRW-3852 |
Describe the bug
When starting a che-code based workspace the IDE gets loaded a first time and shows an error message (Error loading webview) and after a few seconds gets reloaded:
vs-code-loading-twice.mov
Che version
next (development version)
Steps to reproduce
Click here (access to Che dogfooding instance is required).
Expected behavior
VS Code is loaded once.
Runtime
OpenShift
Screenshots
No response
Installation method
OperatorHub
Release Notes Text
An extension was used to open the project folder at VS Code startup. The result was VS Code beeing loaded twice in the user browser. This is not necessary anymore as we use the VS Code startup parameter
--default-folder
that has been (re-)introduced recently.The text was updated successfully, but these errors were encountered: