Skip to content

Fix workspace location when opening in vscode desktop #11131

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 2 commits into from
Jul 7, 2022

Conversation

jeanp413
Copy link
Member

@jeanp413 jeanp413 commented Jul 5, 2022

Related Issue(s)

Fixes #11101

How to test

  1. Select vscode desktop in dashboard
  2. Open https://gitlab.com/bakins-bits/gitpod-setup-for-bitcoin-core-dev in prev env
  3. When vscode desktop connects to workspace check the workspace openup with three folders by default - bitcoin btcdeb gitpod-setup-for-bitcoin-core-dev

Release Notes

NONE

Werft options:

  • /werft with-preview

@jeanp413 jeanp413 requested a review from a team July 5, 2022 02:41
@jeanp413
Copy link
Member Author

jeanp413 commented Jul 5, 2022

/werft run

👍 started the job as gitpod-build-jp-fix-ws-location.1
(with .werft/ from main)

@jeanp413 jeanp413 force-pushed the jp/fix-ws-location branch from 2875a93 to 0454f4d Compare July 5, 2022 03:14
@jeanp413
Copy link
Member Author

jeanp413 commented Jul 5, 2022

/werft run with-clean-slate-deployment

👍 started the job as gitpod-build-jp-fix-ws-location.3
(with .werft/ from main)

@jeanp413 jeanp413 force-pushed the jp/fix-ws-location branch from 0454f4d to 5bd68f7 Compare July 5, 2022 03:38
@akosyakov
Copy link
Member

akosyakov commented Jul 5, 2022

@jeanp413 It does not seem to work for me. It always opens / for me.
Screenshot 2022-07-05 at 08 42 51

I tried both latest and stable.

Copy link
Contributor

@mustard-mh mustard-mh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't see any differences between prev env and prod env (I use Open in VS Code command in browser code)

BTW. I found a bug (prod env) that after a close Desktop VSCode, browser code's terminals will be terminated...Maybe I should file an issue?

@akosyakov
Copy link
Member

BTW. I found a bug (prod env) that after a close Desktop VSCode, browser code's terminals will be terminated...Maybe I should file an issue?

It is known and fixed, but needs a new release of VS Code Desktop, please see #11101 (comment)

@jeanp413
Copy link
Member Author

jeanp413 commented Jul 5, 2022

I can't see any differences between prev env and prod env (I use Open in VS Code command in browser code)

@mustard-mh You need to select vscode desktop in dashboard, using vscode web uses a different logic in gitpod-web

@roboquat roboquat added size/M and removed size/XS labels Jul 6, 2022
@mustard-mh mustard-mh force-pushed the jp/fix-ws-location branch from 198325c to 2c5cd4c Compare July 7, 2022 07:55
@mustard-mh
Copy link
Contributor

rebased to origin/main to fix build error

@mustard-mh
Copy link
Contributor

mustard-mh commented Jul 7, 2022

@mustard-mh You need to select vscode desktop in dashboard, using vscode web uses a different logic in gitpod-web

Not works too

Not works since I expected what How to Test section said

file bitcoin.code-workspace is open by default

I will update PR description

@mustard-mh
Copy link
Contributor

And why this PR can fix issue #11101 ?

@mustard-mh
Copy link
Contributor

We should remove contentReady in JetBrains too

// wait until content ready
contentStatus, wsInfo, err := resolveWorkspaceInfo(context.Background())
if err != nil || wsInfo == nil || contentStatus == nil || !contentStatus.Available {
log.WithError(err).WithField("wsInfo", wsInfo).WithField("cstate", contentStatus).Error("resolve workspace info failed")
return
}
log.WithField("cost", time.Now().Local().Sub(startTime).Milliseconds()).Info("content available")

@mustard-mh
Copy link
Contributor

And why this PR can fix issue #11101 ?

Terminal issue will be fixed by Microsoft right? and this PR to fix the first open file related in #11101 ?

@mustard-mh
Copy link
Contributor

mustard-mh commented Jul 7, 2022

Our docs about workspaceLocation are wrong .gitpod.yml ref and workspace location doc we should change them. It means the pointer of .code-workspace file as our schema said.

Doc makes me confused 🥲

@loujaybee @jeanp413

Copy link
Contributor

@mustard-mh mustard-mh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice job JP 🎉 Need to change #11131 (comment)

I tested this PR in prev env with vscode desktop selected, it works as expected - open up with three folders.

Prod Prev Env
image image

@jeanp413 jeanp413 force-pushed the jp/fix-ws-location branch from 2c5cd4c to 8f432a9 Compare July 7, 2022 18:03
@jeanp413 jeanp413 requested a review from mustard-mh July 7, 2022 18:04
@mustard-mh
Copy link
Contributor

Also tested with JetBrains and it didn't break

image

Copy link
Contributor

@mustard-mh mustard-mh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@roboquat roboquat merged commit 83c4601 into main Jul 7, 2022
@roboquat roboquat deleted the jp/fix-ws-location branch July 7, 2022 20:58
@roboquat roboquat added deployed: IDE IDE change is running in production deployed Change is completely running in production labels Jul 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deployed: IDE IDE change is running in production deployed Change is completely running in production release-note-none size/M team: IDE
Projects
None yet
Development

Successfully merging this pull request may close these issues.

multi-repo: opening workspace file loses task's terminal window (desktop VSCode)
4 participants