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

fix: make workspace restart more informative #363

Merged
merged 7 commits into from
May 31, 2024

Conversation

vitaliy-guliy
Copy link
Contributor

@vitaliy-guliy vitaliy-guliy commented May 27, 2024

What does this PR do?

  • bumps to @eclipse-che/che-devworkspace-generator:7.86.0
  • displays a reason of a failure when trying to restart the workspace from a local devfile
  • allows to easily open the devfile by a notification button

Screenshot from 2024-05-28 18-55-59

What issues does this PR fix?

eclipse-che/che#22913

How to test this PR?

      env:
        - name: test
          value: true

The yaml extension should underline true as one that has wrong type (considering devfile schema it should be string instead of boolean).

  • run Eclipse Che: Restart Workspace from Local Devfile command and select the devfile
    ( if there is only one devfile in the project, you can press Enter several times to confirm the reload )

  • at this step you should be warned with an explanation of the reason of failure

Does this PR contain changes that override default upstream Code-OSS behavior?

  • the PR contains changes in the code folder (you can skip it if your changes are placed in a che extension )
  • the corresponding items were added to the CHANGELOG.md file
  • rules for automatic git rebase were added to the .rebase folder

Signed-off-by: vitaliy-guliy <vgulyy@redhat.com>
Signed-off-by: vitaliy-guliy <vgulyy@redhat.com>
Copy link

github-actions bot commented May 27, 2024

Click here to review and test in web IDE: Contribute

Copy link

Pull Request Dev image published:
👉 quay.io/che-incubator-pull-requests/che-code-dev:pr-363-dev-amd64

@vitaliy-guliy vitaliy-guliy added the made-with-che Changes made with Che-Code label May 27, 2024
Signed-off-by: vitaliy-guliy <vgulyy@redhat.com>
Copy link

Pull Request Dev image published:
👉 quay.io/che-incubator-pull-requests/che-code-dev:pr-363-dev-amd64

Signed-off-by: vitaliy-guliy <vgulyy@redhat.com>
Copy link

Pull Request Dev image published:
👉 quay.io/che-incubator-pull-requests/che-code-dev:pr-363-dev-amd64

Signed-off-by: vitaliy-guliy <vgulyy@redhat.com>
Copy link

Pull Request Dev image published:
👉 quay.io/che-incubator-pull-requests/che-code-dev:pr-363-dev-amd64

Signed-off-by: vitaliy-guliy <vgulyy@redhat.com>
Copy link

Pull Request Dev image published:
👉 quay.io/che-incubator-pull-requests/che-code-dev:pr-363-dev-amd64

Copy link

Pull Request Che-Code image published:
👉 quay.io/che-incubator-pull-requests/che-code:pr-363-amd64

@vitaliy-guliy vitaliy-guliy changed the title Catch devfile errors fix: make workspace restart more informative May 28, 2024
@vitaliy-guliy vitaliy-guliy marked this pull request as ready for review May 28, 2024 15:59
@vitaliy-guliy vitaliy-guliy requested a review from svor May 28, 2024 16:00
@@ -41,7 +41,8 @@
"@types/fs-extra": "^9.0.13",
"@types/jest": "^27.4.0",
"@types/js-yaml": "^4.0.5",
"@types/node": "18.x"
"@types/node": "18.x",
"eslint": "^8.0.0"
},
Copy link
Contributor

Choose a reason for hiding this comment

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

please update yarn.lock file

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

Signed-off-by: vitaliy-guliy <vgulyy@redhat.com>
Copy link

Pull Request Dev image published:
👉 quay.io/che-incubator-pull-requests/che-code-dev:pr-363-dev-amd64

Copy link

Pull Request Che-Code image published:
👉 quay.io/che-incubator-pull-requests/che-code:pr-363-amd64

Copy link
Contributor

@RomanNikitenko RomanNikitenko left a comment

Choose a reason for hiding this comment

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

tested,
works as described in the PR description

Copy link
Contributor

@svor svor left a comment

Choose a reason for hiding this comment

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

lgtm

screenshot-che-dogfooding apps che-dev x6e0 p1 openshiftapps com-2024 05 31-13_07_55

@vitaliy-guliy vitaliy-guliy merged commit d7587cc into main May 31, 2024
7 checks passed
@vitaliy-guliy vitaliy-guliy deleted the catch-devfile-errors branch May 31, 2024 12:08
@devstudio-release
Copy link

Build 3.15 :: code_3.x/1414: Console, Changes, Git Data

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

Build 3.15 :: code_3.x/1414: SUCCESS

Upstream sync done; /DS_CI/sync-to-downstream_3.x/6905 triggered

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

Build 3.15 :: get-sources-rhpkg-container-build_3.x/6857: FAILURE

devspaces-operator-bundle : 3.x :: Failed in 61615147 : BREW:BUILD/STATUS:UNKNOWN
FAILURE:; copied to quay

@the-it-jaeger
Copy link

This change is great @vitaliy-guliy, thank you!

I found one edge case: If the ServiceAccount running the DevWorkspace Pod does not have the appropriate k8s Role (permissions), you still get ambiguous HTTP Request errors when trying to perform actions such as "Dev Spaces: Restart Workspace from Local Devfile."

I discovered this when I had to override the default ServiceAccount so I could apply a custom SecurityContextContstraing and some extra securityContext for a special container component that had to run as a non-random user.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
made-with-che Changes made with Che-Code
Projects
None yet
5 participants