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

[UD] A new workspace cannot be created if the target devfile includes a parent with the storage-type field #23309

Open
olexii4 opened this issue Jan 9, 2025 · 2 comments
Assignees
Labels
area/dashboard kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.

Comments

@olexii4
Copy link
Contributor

olexii4 commented Jan 9, 2025

Describe the bug

A new workspace cannot be created if it is based on a devfile with a parent with the storage-type field e.g.

...
metadata:
attributes:
  controller.devfile.io/storage-type: ephemeral
...

Che version

7.97@latest

Steps to reproduce

  1. Try to create a new workspace from the source
https://gist.githubusercontent.com/olexii4/dfb21012e08eedf8fc17ae608708fe87/raw/bec54efa905b915695dcb7fc5806cb4b456aa343/devfile.yaml
  1. You can see an error message:
    Знімок екрана 2025-01-07 о 17 28 19

Expected behavior

  1. Try to create a new workspace from the source
https://gist.githubusercontent.com/olexii4/dfb21012e08eedf8fc17ae608708fe87/raw/bec54efa905b915695dcb7fc5806cb4b456aa343/devfile.yaml
  1. A new workspace should be created without errors.

Runtime

OpenShift

Screenshots

No response

Installation method

chectl/next

Environment

macOS

Eclipse Che Logs

No response

Additional context

No response

@olexii4 olexii4 added the kind/bug Outline of a bug - must adhere to the bug report template. label Jan 9, 2025
@che-bot che-bot added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Jan 9, 2025
@olexii4 olexii4 self-assigned this Jan 9, 2025
@olexii4 olexii4 added severity/P1 Has a major impact to usage or development of the system. area/dashboard labels Jan 9, 2025
@olexii4 olexii4 removed the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Jan 9, 2025
@ibuziuk ibuziuk moved this to Unplanned Tasks in Eclipse Che Team A Backlog Jan 9, 2025
@ibuziuk
Copy link
Member

ibuziuk commented Jan 9, 2025

@olexii4 some relevant discussion related to this issue - devfile/registry#401 (comment)

@thepetk @michael-valdron wdyt should be the right behaviour, imo the attributes defined in the child devfile should get the priotity

@RomanNikitenko RomanNikitenko changed the title [UD] A new workspace cannot be created if the target davfile includes a parent with the storage-type field [UD] A new workspace cannot be created if the target devfile includes a parent with the storage-type field Jan 10, 2025
@thepetk
Copy link

thepetk commented Jan 10, 2025

Yeah I think is quite similar with devfile/registry#401 (comment)

I was able to reproduce the error using an updated version of mine:

@thepetk @michael-valdron wdyt should be the right behaviour, imo the attributes defined in the child devfile should get the priotity

I would expect that the following structure should be ok to override the parent attributes:

parent:
    uri: "...."
    attributes:
          controller.devfile.io/storage-type: empheral

However this is not the case, as the parent schema does not support overrides in the attributes field. Therefore, I would expect that if passed correctly (through the parent block), no change would be applied to the parent devfile as it's not supported, BUT we should be able to create the workspace.

I can confirm this is not the case too. See:

One question I have: Are there any additions to the child devfile attributes done by default from Devworkspace during the workspace creation process? This would justify the above error as both parent & child could share the same block. More specifically is the:

attributes:
  controller.devfile.io/storage-type:

added in any of the steps to the devfile we are trying to create a workspace from?

The main reason I'm asking is what I described above. In case no attributes.controller.devfile.io/storage-type exists in the child devfile, we shouldn't get an error of having the same attributes both in child and parent.

NOTE: FWIW I can confirm that this is not a generic issue for the attributes therefore, if I change the attribute in parent to a dummy attribute value the issue is gone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dashboard kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.
Projects
Status: Unplanned Tasks
Development

No branches or pull requests

4 participants