Skip to content

Conda pylint installation fails due to broken whitespace handling #2015

Closed

Description

Environment data

  • VS Code version: 1.24.1
  • Extension version: 2018.5.0
  • OS and version: Windows 10
  • Python version: Anaconda (conda 4.5.4, Python 3.6.5)
  • Type of virtual environment used: conda
  • Relevant/affected Python packages and their versions: none

Actual behavior

The extension offers to install pylint for me. I click "Install" and the popup asks me whether I want to install it using conda or pip. I choose conda. The installation fails (see below for the output log).

Expected behavior

The installation succeeds.

Steps to reproduce:

  1. Create a conda environment with a name containing at least one whitespace
  2. Activate this conda environment in Visual Studio Code
  3. Choose to install pylint using conda when prompted to by the extension

One can see in the output below that while the activate command properly handles the whitespace in the environment name, the conda install command does not.

Logs

Windows PowerShell
Copyright (C) 2016 Microsoft Corporation. All rights reserved.

PS C:\Users\dthul> & cmd /k "activate ""My Conda Environment"" & powershell"
Windows PowerShell
Copyright (C) 2016 Microsoft Corporation. All rights reserved.

PS C:\Users\dthul> & conda install --name My Conda Environment pylint

EnvironmentLocationNotFound: Not a conda environment: C:\Users\dthul\AppData\Local\Continuum\Anaconda3\envs\My

Output from Console under the Developer Tools panel:

[Extension Host] Python Extension: Linter 'pylint' is not installed. Please install it or select another linter". Error: Module 'pylint' not installed.
	at PythonExecutionService.<anonymous> (C:\Users\dthul\.vscode\extensions\ms-python.python-2018.5.0\out\client\common\process\pythonProcess.js:96:27)
	at Generator.next (<anonymous>)
	at fulfilled (C:\Users\dthul\.vscode\extensions\ms-python.python-2018.5.0\out\client\common\process\pythonProcess.js:12:58)
	at <anonymous>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

area-terminalbugIssue identified by VS Code Team member as probable bugimportantIssue identified as high-priority

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions