Skip to content

Commit

Permalink
Don't pass empty object as "env_vars" (#50)
Browse files Browse the repository at this point in the history
This causes crash when passed to like so: subprocess.Popen(..., env={}).

Fixes #49
  • Loading branch information
rchl authored Aug 23, 2021
1 parent 4c79508 commit 15d01c5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
7 changes: 3 additions & 4 deletions LSP-pylsp.sublime-settings
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,12 @@
"settings": {
// --- JEDI configuration ---------------------------------------------
// Additional paths to extend the JEDI engine with.
// If you are using a virtual environment, specify a path to it to here.
// "pylsp.plugins.jedi.environment": "./.venv/myproject",
"pylsp.plugins.jedi.extra_paths": ["$sublime_py_files_dir", "$packages"],
// Define environment variables for jedi.Script and Jedi.names.
"pylsp.plugins.jedi.env_vars": {},
// Define environment for jedi.Script and Jedi.names.
// If you are using a virtual environment, specify a path to it to here. For example: "./.venv/myproject",
"pylsp.plugins.jedi.environment": null,
// Define environment variables for jedi.Script and Jedi.names.
"pylsp.plugins.jedi.env_vars": null,
// Enable or disable the plugin.
"pylsp.plugins.jedi_completion.enabled": true,
// Modules for which the labels should be cached.
Expand Down
9 changes: 7 additions & 2 deletions sublime-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,13 @@
}
},
"pylsp.plugins.jedi.env_vars": {
"type": "object",
"items": {
"type": [
"object",
"null"
],
"default": null,
"minProperties": 1,
"additionalProperties": {
"type": "string"
},
"description": "Define environment variables for jedi.Script and Jedi.names."
Expand Down

0 comments on commit 15d01c5

Please sign in to comment.