redhat-developer / redhat-developer/yaml-language-server

Missing required property value reported as type error

Open
#848 2 comments 1 reaction 1 assignee View on GitHub

@msivasubramaniaan is already working on this.

Since Mar 2, 2023.

  • #855 by @msivasubramaniaan — closed without merging
bug
Dominant language
TypeScript
Stars
1.5k
Forks
352
Avg merge
2d 7h
Merged PRs (30d)
11

Description

Describe the bug

A missing required property is reported as a type error.

image

Incorrect type. Expected "string".

image

This is likely due to the YAML to JSON conversion which inserts a null where the yaml has no value.

Expected Behavior

The error should be reported as a missing value.

Current Behavior

The error is reported as at type error.

Steps to Reproduce

  1. Copy and open this blueprint in vscode where the yaml-language-server is installed.
  2. Add this yaml-language-server schema declaration: https://raw.githubusercontent.com/Cloud-Schematics/vscode-blueprint-schema/master/blueprint_schema.json
  3. Remove the value of the name of one of the modules.

Environment

  • Windows
  • Mac
  • Linux
  • other (please specify)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.