Skip to content

IntelliSense/Autocomplete not working for merged Jsonnet objects #242

Description

@krishna1633

The Jsonnet Language Server provides IntelliSense for direct imports but not for objects created by merging imported objects.This is a common pattern in Jsonnet codebases where libraries are imported and then merged with configuration. The LSP should be able to infer that merged objects retain the same structure as the base object.

Steps to Reproduce:

  1. Import a Jsonnet library: local kubeBase = (import 'kube.libsonnet');
  2. Merge it with configuration: local kube = kubeBase { namespace:: 'test', ... };
  3. Try to use IntelliSense: Type kube. - no autocomplete appears
  4. Compare with: Type kubeBase. - autocomplete works correctly

Environment:

  • Extension: Grafana Jsonnet v0.7.2
  • Jsonnet Language Server version: 0.16.0
  • Editor: Cursor 2.3.29
  • OS: Debian GNU/Linux 12 (bookworm) on Linux 6.8.0-1030-azure (Azure Codespaces)
  • Architecture: x86_64

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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