Skip to content

QuickFix not rendering on number/integer allowed values #1116

@arunvenmany-ibm

Description

@arunvenmany-ibm

Describe the bug

Quick fix not working when the object type is number/integer

Image Image

property "severity" is defined as type "number" and "statusCode" is defined as "integer"
Image

Attaching schema for reference

test3.json

Expected Behavior

Quick fix options should be visible

Current Behavior

Quickfix options are not rendering

Steps to Reproduce

  1. Create a new yaml.file
  2. Use inline schema test.json, attached
  3. Autocomplete yaml and add severity/ statusCode field with invalid value
  4. Try quickfix code action

Environment

  • Windows
  • Mac
  • Linux

Additional info

Checked the code in yamlCodeActions.ts

Image

CodeAction title is expected to be a string always. Wrapping with String() for title resolves the issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions