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

got error : CodeLLDB requires Python 3.6(64bit), but looks like it is not installed on this machine #157

Closed
ThiyamSingh opened this issue Jan 7, 2019 · 18 comments
Labels
cause:CodeLLDB The cause has been determined to be in this project

Comments

@ThiyamSingh
Copy link

Which OS: Windows 10 1809 (build 17763.195)
Which VSCode version: 1.30.1
Which extension version: lldb

Which adapter type:
Which LLDB version: 1.2.0

What is the problem and how did you get there:
I got an error "CodeLLDB requires Python 3.6(64bit), but looks like it is not installed on this machine." when I click on Start debugging green button in VS Code. After I install the Python 3.6, still the same error displayed.

error

Thanks

@vadimcn
Copy link
Owner

vadimcn commented Jan 7, 2019

Did you install the 64-bit one?

@vadimcn vadimcn added the waiting for info Waiting for the issue author to provide more information. label Jan 7, 2019
@ThiyamSingh
Copy link
Author

Yes I have installed 64-bit python.

@vadimcn
Copy link
Owner

vadimcn commented Jan 7, 2019

What do you get if you run reg query HKLM\Software\Python\PythonCore\3.6\InstallPath ?

@ThiyamSingh
Copy link
Author

I got
image

But I have installed python3.6(64-bit).
image

Regards,
Sunny

@vadimcn
Copy link
Owner

vadimcn commented Jan 8, 2019

What about reg query HKLM\Software\Python\PythonCore\3.6\InstallPath /reg:64?
Are you using a 32-bit VSCode?

@ThiyamSingh
Copy link
Author

ThiyamSingh commented Jan 8, 2019

I got the same error,
image

I have found a difference in registry. Python is registered under "HKEY_CURRENT_USER" but not under "HKEY_LOCAL_MACHINE" .

@vadimcn
Copy link
Owner

vadimcn commented Jan 8, 2019

Ahh, ok, so you've installed Python for current user only?

@vadimcn vadimcn added cause:CodeLLDB The cause has been determined to be in this project and removed waiting for info Waiting for the issue author to provide more information. labels Jan 8, 2019
@ThiyamSingh
Copy link
Author

Now I have resolved the issue with configuring python manually under "HKEY_LOCAL_MACHINE". After running the debug I got no error messages and not hitting on any breakpoints.
I am sharing the screenshot of the terminal output below,
image

Regards,
Sunny

@Infl1ght
Copy link

Unfortunately I have got the same issue...

@vrgtms
Copy link

vrgtms commented Jan 21, 2019

+1 :(

@vrgtms
Copy link

vrgtms commented Jan 21, 2019

I've got it to work. The solution is:

  1. Open %userprofile%\.vscode\extensions\vadimcn.vscode-lldb-1.2.0\extension\adapter.js
  2. In the line How to make it work interactively with the editor? #65 change the first argument of the util.readRegistry to 'HKEY_CURRENT_USER\Software\Python\PythonCore\3.6\InstallPath'
  3. Save, reload vscode.

Tested on rust code, on 64bit windows 7, works fine.

@vrgtms
Copy link

vrgtms commented Jan 21, 2019

Made a pull request for that. As I can tell it fails because the pipeline configs.

@vadimcn
Copy link
Owner

vadimcn commented Feb 4, 2019

Should be fixed in 1.2.1

@vadimcn vadimcn closed this as completed Feb 4, 2019
@JohannesBeranek
Copy link

Same issue again when installing current python 3.7.2 which is the one listed as "Latest python 3 release" on the python website

@vadimcn
Copy link
Owner

vadimcn commented Feb 19, 2019

Different minor versions of Python are not binary-compatible. Because LLDB I am bundling was built against 3.6, it has to be Python 3.6.x, not 3.7 or 3.8.

@fleimgruber
Copy link

@vadimcn What is your opinion on supporting custom Python install locations (with matching minor ABI), e.g. of a virtual environment or conda environment? IMHO users of these tools usually do not use the official Python installers.

@schungx
Copy link

schungx commented Feb 16, 2020

Setting PYTHONHOME works for different Python versions > 3.3.

@MACDfree
Copy link

Setting PYTHONHOME works for different Python versions > 3.3.

This can be demonstrated by the following code:

https://github.com/vadimcn/vscode-lldb/blob/874ac867ac413865af4fe07817ea537d253ad42f/adapter2/loader/find_python.rs#L118

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cause:CodeLLDB The cause has been determined to be in this project
Projects
None yet
Development

No branches or pull requests

8 participants