pywin32 icon indicating copy to clipboard operation
pywin32 copied to clipboard

`Pythonwin.exe /new /run` silently fails and does nothing in Python Development Mode (w/ Fault handlers enabled)

Open Avasam opened this issue 8 months ago • 0 comments

For all bugs, please provide the following information:

Expected behavior and actual behavior

Using the reproduction steps below, I'd expect

Image (I purposefully omitted the final argument so that Pythonwin would stay open)

But instead nothing happens, pure silence. No stdout nor stderr. And return code of 1. Nothing in the event viewer either.

Steps to reproduce the problem

  1. Set PYTHONDEVMODE=1 or PYTHONFAULTHANDLER=1. In powershell, that's $Env:PYTHONDEVMODE=1
  2. Locate Pythonwin.exe (for me that's C:\Users\Avasam\AppData\Local\Programs\Python\Python310\lib\site-packages\Pythonwin\Pythonwin.exe)
  3. Locate Pythonwin/pywin/test/_exetestscript.py
  4. Adapt the command to your paths, but run C:\Users\Avasam\AppData\Local\Programs\Python\Python310\lib\site-packages\Pythonwin\Pythonwin.exe /new /run e:\Users\Avasam\Documents\Git\pywin32\Pythonwin\pywin\test\_exetestscript.py

System information

Python version and distribution: Python 3.10.11

pywin32 version: latest build from main (https://github.com/mhammond/pywin32/commit/90289ebaa468ccee64bd0e8b374a11bf1e54daa0 as of writing this issue)

Windows Version: Version 10.0.19045 Build 19045

DLL locations:

C:\Users\Avasam\AppData\Local\Programs\Python\Python310\lib\site-packages\pywin32_system32\pywintypes310.dll
C:\Users\Avasam\AppData\Local\Programs\Python\Python310\lib\site-packages\pywin32_system32\pythoncom310.dll

Additional informaiton

This is a blocker for https://github.com/mhammond/pywin32/pull/2502

Avasam avatar Mar 27 '25 04:03 Avasam