On Windows 10, lldb gets error regarding module encodings #58447
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
cloned
Resolution: Was resubmitted in the appropriate repository rather than transferred
documentation
inaccurate info
Bug → documentation: Inaccurate info
† website
This issue was supposed to belong in the swift-org-website repository
Windows
Platform: Windows
This is due to a "bug" in the Swift installation procedure for Windows 10. Below, after describing the issue, I have a solution. I am new at Swift, and other thoughts are welcome!
Environment
build number: Swift 5.6.1
OS: Windows 10 desktop computer
Issue Description
On Windows 10, lldb gets error: Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding. error: ModuleNotFoundError: No module named 'encodings'
Test Case
After an install of Swift on Windows 10, run 'lldb Factorial' as shown on Swift - Getting Started > Using the LLDB Debugger. That elicits the error above.
Cause
The env var PYTHONPATH is missing the Python directory: (your-Python-root)\Lib.
Solution
See notes on PYTHONPATH in #58438.
The text was updated successfully, but these errors were encountered: