Skip to content
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

Add support for JetBrains EAP IDEs (2022.3) #13400

Merged
merged 1 commit into from
Sep 29, 2022

Conversation

felladrin
Copy link
Contributor

@felladrin felladrin commented Sep 28, 2022

Description

Now that IDEA/PyCharm/PhpStorm/GoLand latest version is v2022.3 in Gitpod, we can add support for JetBrains IDEs v2022.3.

All code changes were done to accommodate the API differences between v2022.2 and v2022.3. There were no logic/flow changes in the plugin.

The dev server script (launch-dev-server.sh) has been improved to allow us locally test EAP and Stable versions of the IDE, which is a common point of failure during Werft builds - because there we build the plugin for EAP and Stable IDE versions simultaneously.
- By default, running launch-dev-server.sh, will launch the JetBrains EAP version.
- If we want to build launch JetBrains Stable version we run it with the additional 's' parameter: launch-dev-server.sh -s

How to test

1. Access the Preview Environment of this PR
2. Open a workspace using the Stable Version of IntelliJ IDEA and check if the Control Center is being displayed correctly and that the IDE shows no errors about Gitpod Plugin.
3. Do the same as Step 2, but now using the Latest Stable Version of IntelliJ IDEA.

We won't be able to test on preview environments, as the EAP JetBrains IDEs versions are pinned to 2022.2.1 during the Self-Hosted release. So please test it on gitpod.io by following these steps:

  1. Having the Stable IntelliJ IDEA selected as IDE, access https://gitpod.io/#referrer:jetbrains-gateway:intellij/https://github.com/gitpod-io/gitpod/pull/13400
  2. On terminal, run: cd components/ide/jetbrains/backend-plugin/
  3. Then run: ./launch-dev-server.sh -s to launch the Stable Version of IntelliJ IDEA and check if the Control Center is being displayed correctly and that the IDE shows no errors about Gitpod Plugin.
    image
  4. Stop the command above and run rm -rf /workspace/ide-backend
  5. Now run: ./launch-dev-server.sh to launch the Latest Stable Version of IntelliJ IDEA, and do the same checks from Step 3.
    image

Release Notes

Gitpod Plugin was updated to work with the JetBrains IDEs v2022.3 (EAP).

Werft options:

  • /werft with-local-preview
    If enabled this will build install/preview
  • /werft with-preview
  • /werft with-large-vm
  • /werft with-integration-tests=all
    Valid options are all, workspace, webapp, ide

@@ -141,7 +137,7 @@ class GitpodClientProjectSessionTracker(
override fun onNext(ps: Status.PortsStatusResponse) {
for (port in ps.portsList) {
// Avoiding undesired notifications
if (ignorePorts.contains(port.localPort)) {
if (ignoredPortsForNotificationService.getIgnoredPorts().contains(port.localPort)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

The ignore ports functionality seems to be overcomplicated now, instead of being 3 lines of code, we have 3 files. Am I missing any benefit from doing so?

Copy link
Contributor Author

@felladrin felladrin Sep 28, 2022

Choose a reason for hiding this comment

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

We need one version for 2022.2 API [1] and another for 2022.3 [1].

Or we can remove the ignored ports part.

Copy link
Contributor

@andreafalzetti andreafalzetti Sep 28, 2022

Choose a reason for hiding this comment

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

oh, I see - thanks!

@gitpod-io gitpod-io deleted a comment from werft-gitpod-dev-com bot Sep 28, 2022
Copy link
Contributor

@andreafalzetti andreafalzetti left a comment

Choose a reason for hiding this comment

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

Tested and works as expected.

I see there is an Update warn message but I am not sure how to see its details (no way to see what needs update 🤔 )
Screenshot 2022-09-28 at 12 47 24

/hold

@felladrin
Copy link
Contributor Author

felladrin commented Sep 28, 2022

Werft is failing to create the Preview Environments for this PR, so I added instructions for testing it from the Production environment in the PR Description.

@andreafalzetti
Copy link
Contributor

andreafalzetti commented Sep 28, 2022

/werft run

👍 started the job as gitpod-build-felladrin-jetbrains-ides-2022.3.7
(with .werft/ from main)

@felladrin
Copy link
Contributor Author

felladrin commented Sep 29, 2022

ℹ️ I'm going to rebase this PR on the latest commit from the main branch.

@andreafalzetti
Copy link
Contributor

@felladrin if Werft keeps failing, I suggest create a new branch and move the PR to a new one (with new prev env)

@felladrin
Copy link
Contributor Author

Something is wrong with the connection between Gitpod Build and and this Github PR, cause the latest build is working fine:
https://werft.gitpod-dev.com/job/gitpod-build-felladrin-jetbrains-ides-2022.3.12, but in the PR it's taking the result of https://werft.gitpod-dev.com/job/gitpod-build-felladrin-jetbrains-ides-2022.3.10

Note: I've unchecked the /werft with-preview due to the issue of Preview Environments having EAP JetBrains IDEs versions at 2022.2.1 instead of 2022.3. [Internal Discussion]

@andreafalzetti
Copy link
Contributor

@felladrin I've followed the manual steps and it works as expected. Using -s I see 2022.2.2 and with latest I see 2022.3

I think you need an admin now to merge this PR given the failed Werft check.

@felladrin
Copy link
Contributor Author

felladrin commented Sep 29, 2022

/werft run

👍 started the job as gitpod-build-felladrin-jetbrains-ides-2022.3.13
(with .werft/ from main)
Let me try one more time.

@andreafalzetti
Copy link
Contributor

/unhold

@roboquat roboquat merged commit bdd7951 into main Sep 29, 2022
@roboquat roboquat deleted the felladrin/jetbrains-ides-2022.3 branch September 29, 2022 13:10
@roboquat roboquat added deployed: IDE IDE change is running in production deployed Change is completely running in production labels Sep 30, 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 editor: jetbrains release-note size/L team: IDE
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants