Message298754
subprocess.Popen calls WinAPI CreateProcess, which can execute PE/COFF executables and .BAT/.CMD batch scripts. It doesn't know anything about .LNK shell shortcuts. If CreateProcess fails, a Windows shell (e.g. CMD or PowerShell) tries ShellExecuteEx, which knows how to open a .LNK file. You can use shell=True for this in Python.
Directly supporting ShellExecuteEx would be a major enhancement. It would probably require a new keyword-only parameter, or at least a sentinel value for the existing `shell` parameter. |
|
Date |
User |
Action |
Args |
2017-07-20 23:26:29 | eryksun | set | recipients:
+ eryksun, paul.moore, tim.golden, zach.ware, steve.dower, Bernát Gábor |
2017-07-20 23:26:29 | eryksun | set | messageid: <1500593189.4.0.785548275401.issue30979@psf.upfronthosting.co.za> |
2017-07-20 23:26:29 | eryksun | link | issue30979 messages |
2017-07-20 23:26:29 | eryksun | create | |
|