Skip to content

py launcher defaults to the free threaded executable on Windows #144770

@JordanSchlick

Description

@JordanSchlick

Bug report

Bug description:

Using py.exe on Windows, such as when directly executing a .py file, results in the free threaded version of Python being launched.
Even setting py.ini to launch the regular version does not fix this behavior. This results in a situation where a py file can not find modules installed by pip in the same terminal as they are run under different versions of Python.

In my case it always launches python3.14t.exe:

C:\Users\Admin>py --list
 -V:3.14t         Python 3.14 (64-bit, freethreaded)
 -V:3.14 *        Python 3.14 (64-bit)
 -V:3.11          Python 3.11 (64-bit)
 -V:3.9           Python 3.9 (64-bit)
C:\Users\Admin>py -3
Python 3.14.3 free-threading build (tags/v3.14.3:323c59a, Feb  3 2026, 16:00:26) [MSC v.1944 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>

CPython versions tested on:

3.14

Operating systems tested on:

Windows

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions