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

Python v3.0.0 and Spring Boot stack sample doesn't show composite commands in Eclipse Che #1524

Open
dmytro-ndp opened this issue Apr 16, 2024 · 17 comments
Assignees
Labels
area/registry Devfile registry for stacks and infrastructure kind/bug Something isn't working lifecycle/stale Stale items. These items have not been updated for 90 days.

Comments

@dmytro-ndp
Copy link

dmytro-ndp commented Apr 16, 2024

Which area this feature is related to?

/kind bug

Which area this bug is related to?

/area registry

What versions of software are you using?

Eclipse Che Next (7.85.0-SNAPSHOT)
Dev Spaces 3.12.0 deployed to workspaces.openshift.com

Web browser

Operating System and version:

Browser name and version:

Bug Summary

Describe the bug:

When I create workspace using devfile https://github.com/devfile/registry/blob/main/stacks/python/3.0.0/devfile.yaml Eclipse Che 7.85.0 / Dev Spaces 3.12.0, I see no composite commands build-image, deployk8s in the devfile task list in VS Code editor:

  - id: build-image
    apply:
      component: build
  - id: deployk8s
    apply:
      component: deploy
  - id: deploy
    composite:
      commands:
        - build-image
        - deployk8s
      group:
        kind: deploy
        isDefault: true

To Reproduce:

  1. Create and open workspace on DevSandbox using the link https://workspaces.openshift.com/#/https://raw.githubusercontent.com/devfile/registry/main/stacks/python/3.0.0/devfile.yaml
  2. Go to top left menu > Terminal > Run Task...
  3. Open list of devfile commands.

There are only 3 commands in the list:

  • devfile: run-app
  • devfile: pip-install-requirements
  • devfile: debug-py
    Screenshot from 2024-04-16 15-48-36

Expected behavior

Task list includes next composite commands described in the https://github.com/devfile/registry/blob/main/stacks/python/3.0.0/devfile.yaml:

  • devfile: run-app
  • devfile: pip-install-requirements
  • devfile: debug-py
  • devfile: build-image
  • devfile: deployk8s

Any logs, error output, screenshots etc? Provide the devfile that sees this bug, if applicable

Additional context

Any workaround?

Suggestion on how to fix the bug

@thepetk
Copy link
Contributor

thepetk commented Apr 25, 2024

I can confirm the same case happens for all the devfile having commands using the apply instead of exec. (e.g python/3.0.0, go/2.3.0 etc)

@johnmcollier johnmcollier changed the title Python v3.0.0 stack sample doesn't show composite commands in Eclipse Che Python v3.0.0 and Spring Boot stack sample doesn't show composite commands in Eclipse Che Apr 30, 2024
@johnmcollier
Copy link
Member

Spring Boot also affected, see #1526 (comment)

@Jdubrick Jdubrick moved this from Backlog to To Do 📝 in Devfile Project Apr 30, 2024
@Jdubrick Jdubrick moved this from To Do 📝 to In Progress 🚧 in Devfile Project May 8, 2024
@Jdubrick
Copy link
Contributor

Closing this issue as not completed after discussion here in Slack. The only commands that are intended to run via command line are exec and those are properly showing in the devspaces editor. As mentioned in the Slack discussion apply commands are run as init containers and are not intended to show up in an IDE, rather they are for interacting and working with clusters.

While true that you should be able to run composite commands consisting of exec commands, I believe this currently is a limitation of Che as they have an open issue here for adding that functionality. At this time I don't believe there is an issue on the Devfile end for why these are not showing up.

If things change or I am incorrect in my reasoning we can re-open this issue!

@Jdubrick Jdubrick closed this as not planned Won't fix, can't repro, duplicate, stale May 10, 2024
@github-project-automation github-project-automation bot moved this from In Progress 🚧 to Done ✅ in Devfile Project May 10, 2024
@dmytro-ndp dmytro-ndp reopened this May 10, 2024
@Jdubrick
Copy link
Contributor

@dmytro-ndp From my understanding the purpose of those composite commands that are combining two apply commands, build-image and deployk8s, in all of the linked Devfiles is to be able to apply those resources at some time, whether it is preStart or postStart. There may be a default of when they are applied if it is not specified but I'm unsure off the top of my head. The docs related to the schema version applying to those v2.2.0 are here for commands. The API docs here also outline the apply command.

I'm tagging the rest of the team in this comment incase any of them want to fill in any knowledge gaps I may have on this topic!

@devfile/devfile-services-team

@Jdubrick Jdubrick moved this from Done ✅ to In Progress 🚧 in Devfile Project May 10, 2024
@Jdubrick
Copy link
Contributor

@dmytro-ndp Does the above response answer your question?

@dmytro-ndp
Copy link
Author

dmytro-ndp commented May 14, 2024

@Jdubrick : thank you for the answer
I have expected build-image and deployk8s commands to be useful, and somehow involve build and deploy containers along with docker and kubernetes folders.

Shouldn't there be exec commands to build and deploy the Python container, or preStart / postStart in the devfile?
Without those elements devfile looks incomplete, IMHO.

@Jdubrick
Copy link
Contributor

@dmytro-ndp the commands are useful but I believe they may be intended for use with odo and not Che, I could be wrong however I can only think of the use case of them using odo at this time, which also consumes the devfile registry. By using the odo deploy command you can take advantage of the apply commands and the composite that combines them to deploy your project as an outerloop deployment. More on odo deploy here: https://odo.dev/docs/command-reference/deploy

For example, running odo init for me and choosing the python 3.0.0 stack as my starter with the flask starter project, I was able to run odo deploy and it deployed to my minikube cluster:

Image

@ibuziuk
Copy link

ibuziuk commented May 14, 2024

@azatsarynnyy could you please take a look? is it related to eclipse-che/che#21859

@Jdubrick
Copy link
Contributor

Going to move this issue out of sprint as it awaits the investigation from Che and eclipse-che/che#21859. I'll keep myself assigned and can pull it back in if it comes back to the Devfile side. fyi @ibuziuk

@Jdubrick Jdubrick moved this from In Progress 🚧 to Waiting in Devfile Project May 27, 2024
@Jdubrick Jdubrick moved this from Waiting to Backlog in Devfile Project May 27, 2024
@thepetk
Copy link
Contributor

thepetk commented May 27, 2024

Going to move this issue out of sprint as it awaits the investigation from Che and eclipse-che/che#21859. I'll keep myself assigned and can pull it back in if it comes back to the Devfile side. fyi @ibuziuk

cc @devfile/che-team

@yangcao77 yangcao77 moved this from Backlog to Waiting in Devfile Project May 28, 2024
@maysunfaisal
Copy link
Member

@Jdubrick Any updates on this? Should this be in waiting or a blocker?

@Jdubrick
Copy link
Contributor

@maysunfaisal no updates so far regarding this issue. IMO it should be in waiting as it is pending a look from the Che side as the missing functionality is most likely not on the Devfile side and more on limitations of the in browser IDE

@maysunfaisal
Copy link
Member

maysunfaisal commented Jun 10, 2024

@Jdubrick should the priority be downgraded from a blocker if there is no plan for working on it currently?

@Jdubrick
Copy link
Contributor

@Jdubrick should the priority be downgraded from a blocker if there is no plan for working on it currently?

@maysunfaisal Yes most likely, I think major would be appropriate for this issue

@Jdubrick
Copy link
Contributor

Jdubrick commented Jul 8, 2024

Moving to backlog as it has been waiting for some time and there is no timeline for when it will move forward

@Jdubrick Jdubrick moved this from Waiting to Backlog in Devfile Project Jul 8, 2024
Copy link

github-actions bot commented Oct 7, 2024

This issue is stale because it has been open for 90 days with no activity. Remove stale label or comment or this will be closed in 60 days.

@github-actions github-actions bot added the lifecycle/stale Stale items. These items have not been updated for 90 days. label Oct 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/registry Devfile registry for stacks and infrastructure kind/bug Something isn't working lifecycle/stale Stale items. These items have not been updated for 90 days.
Projects
Status: Backlog
Development

No branches or pull requests

6 participants