Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Variables no longer seem to work for pythonPath setting #782

Closed
craigbrett17 opened this issue Feb 14, 2018 · 3 comments
Closed

Variables no longer seem to work for pythonPath setting #782

craigbrett17 opened this issue Feb 14, 2018 · 3 comments
Labels
area-debugging bug Issue identified by VS Code Team member as probable bug
Milestone

Comments

@craigbrett17
Copy link

Environment data

VS Code version: Version 1.20.0
Commit c63189deaa8e620f650cc28792b8f5f3363f2c5b
Date 2018-02-07T17:09:39.780Z
Shell 1.7.9
Renderer 58.0.3029.110
Node 7.9.0
Architecture x64
Python Extension version: 2018.1.0
Python Version: Python 2.7.14 :: Anaconda, Inc.
OS and version: OS Name Microsoft Windows 10 Enterprise 2016 LTSB
Version 10.0.14393 Build 14393

Actual behavior

When I launch the app to debug the current file, I receive the following message:

Error: Failed to launch the Python Process, please validate the path '${workspaceFolder}/virtualenv/python'

The path definitely exists.

Changing the setting to use the full path without the ${workspaceFolder} variable works as expected.

Expected behavior

The file should launch in debug as expected.

Steps to reproduce:

  • Use Annaconda (or similar virtualenv tech) to create a virtualenv in a project
  • Set the python.pythonPath setting to the newly created virtual env using the workspaceFolder or workspaceRoot variable:
"python.pythonPath": "${workspaceFolder}/virtualenv/python",
  • Try launching a python file in debug. You'll receive the error message stated in actual behaviour.
  • Change the setting to point at the pythonpath directly
  • Launch the python file again. It will work as expected.

Logs

Output from Python output panel

N/A

Output from Console window (Help->Developer Tools menu)

Failed to launch the Python Process, please validate the path '${workspaceFolder}/virtualenv/python'
e.doShow @ messageService.ts:126
e.show @ messageService.ts:105
(anonymous) @ debugService.ts:977
v @ winjs.base.raw.js:1209
enter @ winjs.base.raw.js:901
_run @ winjs.base.raw.js:1068
_chainedError @ winjs.base.raw.js:1031
n @ winjs.base.raw.js:736
then @ winjs.base.raw.js:1436
enter @ winjs.base.raw.js:747
_run @ winjs.base.raw.js:1068
_setCompleteValue @ winjs.base.raw.js:1052
v @ winjs.base.raw.js:1209
enter @ winjs.base.raw.js:901
_run @ winjs.base.raw.js:1068
_error @ winjs.base.raw.js:1041
(anonymous) @ v8Protocol.ts:53
e.dispatch @ v8Protocol.ts:136
e.handleData @ v8Protocol.ts:104
(anonymous) @ v8Protocol.ts:41
emitOne @ events.js:96
emit @ events.js:191
readableAddChunk @ _stream_readable.js:178
Readable.push @ _stream_readable.js:136
onread @ net.js:560
console.ts:123 [Extension Host] (node:11552) DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
t.log @ console.ts:123
t._logExtensionHostMessage @ extensionHost.ts:394
(anonymous) @ extensionHost.ts:211
emitTwo @ events.js:106
emit @ events.js:194
process.nextTick @ internal/child_process.js:766
_combinedTickCallback @ internal/process/next_tick.js:73
_tickCallback @ internal/process/next_tick.js:104
@DonJayamanne
Copy link

DonJayamanne commented Feb 15, 2018

Duplicate of #691

@DonJayamanne DonJayamanne marked this as a duplicate of #690 Feb 15, 2018
@DonJayamanne DonJayamanne marked this as a duplicate of #691 Feb 15, 2018
@DonJayamanne DonJayamanne marked this as not a duplicate of #690 Feb 15, 2018
@craigbrett17
Copy link
Author

Okay, fair enough.

@DonJayamanne
Copy link

Please note the issue has been fixed, and you can get the food using the insiders build of the extension. Please check the issue #691 for instructions

@DonJayamanne DonJayamanne added bug Issue identified by VS Code Team member as probable bug closed-duplicate area-debugging labels Feb 15, 2018
@DonJayamanne DonJayamanne added this to the February 2018 milestone Feb 15, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Jul 12, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-debugging bug Issue identified by VS Code Team member as probable bug
Projects
None yet
Development

No branches or pull requests

3 participants