-
-
Notifications
You must be signed in to change notification settings - Fork 33.8k
Closed as not planned
Closed as not planned
Copy link
Labels
3.14bugs and security fixesbugs and security fixes3.15new features, bugs and security fixesnew features, bugs and security fixesOS-windowstopic-installation
Description
Bug report
Bug description:
Project:
main.py
foo/__init__.py
foo/bar.py
main.py
import sys
print(sys.path)
from foo import barstdout:
['C:\\python-3.14.0-embed-amd64\\python314.zip', 'C:\\python-3.14.0-embed-amd64', 'C:\\python-3.14.0-embed-amd64\\Lib\\site-packages']
Traceback (most recent call last):
File "main.py", line 4, in <module>
from foo import bar
ModuleNotFoundError: No module named 'foo'
C:\\python-3.14.0-embed-amd64\\ is in %PATH%
Adding the project folder to sys.path at runtime obviously fixes the problem.
This definitely used to work w/o any workarounds up until at least 3.11 and still works with the free-threaded Python 3.14 build distributed by nuget (https://www.nuget.org/packages/python-freethreaded) so it's more a problem with the binary from https://www.python.org/downloads/windows/ than cpython.
CPython versions tested on:
3.14
Operating systems tested on:
Windows
Metadata
Metadata
Assignees
Labels
3.14bugs and security fixesbugs and security fixes3.15new features, bugs and security fixesnew features, bugs and security fixesOS-windowstopic-installation