Message405677
After upgrading to Windows 11 I can't run Python scripts from a junction folder anymore. Everything else works as before on that folder.
Background: I have Minecraft installed on a second volume (E:\Games\Minecraft). I created a junction folder at %appdata%\.minecraft pointing to that folder. When I try to run a Python script from that folder I get this error:
---
python: can't open file 'C:\Users\xxxxx\AppData\Roaming\.minecraft\test.py': [Errno 22] Invalid argument
---
When trying to debug in VS Code, I get a more detailed error:
---
Traceback (most recent call last):
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2032.0_x64
__qbz5n2kfra8p0\lib\ntpath.py", line 647, in realpath
path = _getfinalpathname(path)
OSError: [WinError 649] The create operation failed because the name
contained at least one mount point which resolves to a volume to
which the specified device object is not attached:
'c:\\Users\\xxxxx\\AppData\\Roaming\\.minecraft'
---
When trying to open that junction folder in Python's IDLE I get the following error message:
---
[Window Title] Location is not available
[Content] C:\Users\xxxxx\AppData\Roaming\.minecraft is not accessible.
The create operation failed because the name contained at least one
mount point which resolves to a volume to which the specified device
object is not attached.
---
I tried creating a symbolic directory link instead of a junction, but got the same message.
I can run the same scripts directly from the target folder (E:\Games\Minecraft).
I can also run them from the junction folder from an Ubuntu terminal on WSL2 (Windows Subsystem for Linux).
I tried this with Python 3.9 and 3.10 (WSL2 uses Python 3.8). |
|
Date |
User |
Action |
Args |
2021-11-04 10:57:57 | fstorino | set | recipients:
+ fstorino, paul.moore, tim.golden, zach.ware, steve.dower |
2021-11-04 10:57:57 | fstorino | set | messageid: <1636023477.57.0.826365620965.issue45710@roundup.psfhosted.org> |
2021-11-04 10:57:57 | fstorino | link | issue45710 messages |
2021-11-04 10:57:57 | fstorino | create | |
|