Skip to content

Autocomplete of class parameters and built-in functions inside classes does not work #769

Open
@nscheer

Description

@nscheer

What Versions are you running?

OS Version: Windows 10 Pro 20H2 / WSL2 with Debian 10
VSCode Version: 1.60.0
Puppet Extension Version: 1.3.0
PDK Version: 2.2.0 (installed in WSL2 Debian)

What You Are Seeing?

In an empty .pp file, built-in function are auto completed, so when I type something like

$x = spl

"split" is suggested. After autocompleting the function it shows its various signatures as well, as I have activated the puppetstrings feature.

But inside a class, built-in functions are not autocompleted anymore:

# Class: test
#
#
class test {
  $x = sp
}

Here I only get "no suggestions".

Furthermore, vscode knows the core data types for class parameters, but does not seem able to autocomplete them:

# Class: test
#
#
class test (
  Str
){

}

So no suggestion for "String" is shown here. If I complete the parameter and hover over "String" it displays "The String core data type".

What is Expected?

Autocompletion of built-in functions inside classes should work. It would be nice if types could be autocompleted as well.

How Did You Get This To Happen? (Steps to Reproduce)

Navigate to an empty folder in WSL2 and open vscode using code .. Create a new file "test.pp".

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions