Skip to content

pyls.plugins.jedi_completion.include_params: default changed recently #534

@nemethf

Description

@nemethf

It seems commit dfff3c9 by @gatesn changed the default value of the config parameter pyls.plugins.jedi_completion.include_params from true to false.

package.json still says its default value is true, so this might be unintentional. Can you, please, change it back to true? I think the following simple patch is probably sufficient.

diff --git a/pyls/plugins/jedi_completion.py b/pyls/plugins/jedi_completion.py
index d2d11cd..4aca0d0 100644
--- a/pyls/plugins/jedi_completion.py
+++ b/pyls/plugins/jedi_completion.py
@@ -49,7 +49,7 @@ def pyls_completions(config, document, position):
     snippet_support = completion_capabilities.get('completionItem', {}).get('snippetSupport')
 
     settings = config.plugin_settings('jedi_completion', document_path=document.path)
-    should_include_params = settings.get('include_params')
+    should_include_params = settings.get('include_params', True)
 
     return [_format_completion(d, snippet_support and should_include_params) for d in definitions] or None

Also, I think it's not possible to set this config variable from different config files (setup.cfg,tox.ini, ...) How should a user set this config parameter?

Thank you.

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