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

Only few functions work in the "redhat/vscode-yaml" plugin. #19091

Closed
18 tasks
Ohrimenko1988 opened this issue Feb 18, 2021 · 3 comments
Closed
18 tasks

Only few functions work in the "redhat/vscode-yaml" plugin. #19091

Ohrimenko1988 opened this issue Feb 18, 2021 · 3 comments
Labels
kind/bug Outline of a bug - must adhere to the bug report template.

Comments

@Ohrimenko1988
Copy link
Contributor

Ohrimenko1988 commented Feb 18, 2021

Describe the bug

Only few functions work in the "redhat/vscode-yaml" plugin.
The list of expected functions got from here yaml plugin
For example work:

  • Yaml validation
  • Format document

don't work:

  • Auto completion (Ctrl + Space)
  • Document Outlining (Ctrl + Shift + O)
  • Hover support:

Che version

  • latest
  • [ x ] nightly
  • other: please specify

Steps to reproduce

  • Create custom workspace using next devfile:
apiVersion: 1.0.0
metadata:
  name: apache-camel-k-dotsq
projects:
  - name: camel-k-examples
    source:
      location: 'https://github.com/apache/camel-k'
      type: git
      sparseCheckoutDir: examples
components:
  - id: redhat/vscode-xml/latest
    type: chePlugin
  - id: redhat/vscode-apache-camel/latest
    type: chePlugin
  - id: redhat/vscode-camelk/latest
    type: chePlugin
    alias: vscode-camelk
  - type: chePlugin
    id: redhat/vscode-yaml/latest
  • Go inside created workspace and open the "camel-k-examples/examples/languages/routes.yaml" file in the editor
  • Try to use auto completion (Ctrl + Space)
  • Pay attention that no appropriate suggestions shown
  • Try to use also "Document outlining" and "Hover support"
  • Pay attention that these features also don't work
  • Also pay attention that "Yaml validation" and "Format" features work

Expected behavior

All plugin features work

Observed behavior

Only a part of features work

Runtime

  • kubernetes (include output of kubectl version)
  • Openshift (include output of oc version)
  • [ x ] minikube (include output of minikube version and kubectl version)
  • minishift (include output of minishift version and oc version)
  • docker-desktop + K8S (include output of docker version and kubectl version)
  • other: (please specify)

Screenshots

Installation method

  • [ x ] chectl
./chectl server:deploy \
  --k8spodreadytimeout=600000 \
  --k8spodwaittimeout=600000 \
  --k8spoddownloadimagetimeout=600000 \
  --listr-renderer=verbose \
  --platform=minikube \
  --chenamespace=eclipse-che \
  --telemetry=off
chectl/7.26.0 linux-x64 node-v12.20.1
  • OperatorHub
  • I don't know

Environment

  • my computer
    • Windows
    • [x ] Linux
    • macOS
  • Cloud
    • Amazon
    • Azure
    • GCE
    • other (please specify)
  • other: please specify

Eclipse Che Logs

Additional context

@Ohrimenko1988 Ohrimenko1988 added the kind/bug Outline of a bug - must adhere to the bug report template. label Feb 18, 2021
@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 Feb 18, 2021
@svor
Copy link
Contributor

svor commented Feb 18, 2021

From the README of vscode-yaml extension: Auto completion and hover support are provided by the schema. Please refer to Language Server Settings to setup a schema
Have you tried to do that?

@JPinkney
Copy link
Contributor

Like @svor said, you'll need to set up a schema. Apache Camel K has a default schema that will be used from the JSON Schema Store, but it's only used when the file name matches "*.camelk.yaml".

To set a schema you can put:

"yaml.schemas": {
      "https://raw.githubusercontent.com/apache/camel-k-runtime/camel-k-runtime-parent-1.5.0/camel-k-loader-yaml/camel-k-loader-yaml/src/generated/resources/camel-yaml-dsl.json": "*.yaml"
   },

in the settings and that schema will be associated with all yaml files. More examples are available here if you don't want to associate that schema to all yaml files: https://github.com/redhat-developer/vscode-yaml#associating-a-schema-to-a-glob-pattern-via-yamlschemas

@Ohrimenko1988
Copy link
Contributor Author

@svor @JPinkney thank you for clarification, I can confirm if apply your suggestions all features work

@amisevsk amisevsk removed the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Feb 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Outline of a bug - must adhere to the bug report template.
Projects
None yet
Development

No branches or pull requests

5 participants