Skip to content

[bug] Empty YAML Mapping Breaks Syntax Highlighting #22

@seandstewart

Description

@seandstewart

Problem

Typing an empty yaml mapping breaks all subsequent syntax highlighting in the given file. If a file already has an empty mapping on load, it will highlight just fine, but if you add a single {, all highllighting after that line disappears.

I saw #5 and assumed this would fix the issue, however with the latest version of this extension, I'm still seeing the issue.

How to reproduce

Have a simple values.yaml like so:

key: value

When you open the file, it will provide correct highlighting. If you add another key with a mapping, syntax highlighting will break until you reload the workspace:

key: value
mapping: {}

Version Info

helm-ls:

❯ helm_ls version
Helm-ls version: 0.5.0
Git commit: Homebrew
Build type: Release
Build time: 2025-07-28T17:22:17Z
Golang: go1.24.5
Compiled by: Homebrew

helm.zed: v0.0.2 (zed-industries/extensions#3336)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions