running "wt.exe" as administrator or with runas/sudo returns no permission error (user context is a normal user) #11635

Closed
opened 2026-01-31 02:53:11 +00:00 by claunia · 5 comments
Owner

Originally created by @Venipa on GitHub (Nov 30, 2020).

Environment


Platform ServicePack Version      VersionString                    
-------- ----------- -------      -------------                    
 Win32NT             10.0.18362.0 Microsoft Windows NT 10.0.18362.0


Windows Terminal version (if applicable):
Windows Terminal Preview
Version: 1.5.3242.0 (also latest stable)
Any other software?
> chocolatey - sudo (just like runas but easier)

Steps to reproduce

  • go to %userprofile%\AppData\Local\Microsoft\WindowsApps
  • run wt.exe as administrator from explorer or with runas command
  • error shown

Gif:
reproductionGif

Expected behavior

run without error message

Actual behavior

errors out a message: "The system is unable to access the file"
image

Originally created by @Venipa on GitHub (Nov 30, 2020). # Environment ```none Platform ServicePack Version VersionString -------- ----------- ------- ------------- Win32NT 10.0.18362.0 Microsoft Windows NT 10.0.18362.0 Windows Terminal version (if applicable): Windows Terminal Preview Version: 1.5.3242.0 (also latest stable) Any other software? > chocolatey - sudo (just like runas but easier) ``` # Steps to reproduce - go to %userprofile%\AppData\Local\Microsoft\WindowsApps - run wt.exe as administrator from explorer or with runas command - error shown Gif: ![reproductionGif](https://i.mavis.moe/f/nKoLFaUtXY/2020-11-30-23-28-05mp4gif.gif) # Expected behavior run without error message # Actual behavior errors out a message: "The system is unable to access the file" ![image](https://user-images.githubusercontent.com/17952364/100674824-1b24a800-3366-11eb-828c-b33dd0dfa9a9.png)
claunia added the Needs-TriageNeeds-Tag-FixResolution-No-Repro labels 2026-01-31 02:53:11 +00:00
Author
Owner

@zadjii-msft commented on GitHub (Dec 1, 2020):

This kinda sounds to me like a bug report that should be filed on sudo, not the Terminal, right? Like, this bug would theoretically reproduce for other "app execution aliases" as well, right? All the other exes in that path are app execution aliases, so can you launch any of those with sudo? (python.exe might be a good example, if you have that installed)

@zadjii-msft commented on GitHub (Dec 1, 2020): This kinda sounds to me like a bug report that should be filed on `sudo`, not the Terminal, right? Like, this bug would theoretically reproduce for other "app execution aliases" as well, right? All the other exes in that path are app execution aliases, so can you launch any of those with `sudo`? (`python.exe` might be a good example, if you have that installed)
Author
Owner

@Venipa commented on GitHub (Dec 1, 2020):

This kinda sounds to me like a bug report that should be filed on sudo, not the Terminal, right? Like, this bug would theoretically reproduce for other "app execution aliases" as well, right? All the other exes in that path are app execution aliases, so can you launch any of those with sudo? (python.exe might be a good example, if you have that installed)

i've also tried running via runas or explorers right click > run as administrator, python works fine but wt.exe always returns the error mentioned above.

@Venipa commented on GitHub (Dec 1, 2020): > This kinda sounds to me like a bug report that should be filed on `sudo`, not the Terminal, right? Like, this bug would theoretically reproduce for other "app execution aliases" as well, right? All the other exes in that path are app execution aliases, so can you launch any of those with `sudo`? (`python.exe` might be a good example, if you have that installed) i've also tried running via runas or explorers right click > run as administrator, python works fine but wt.exe always returns the error mentioned above. ![](https://i.mavis.moe/f/tfWW7xe52W/2020-12-01-14-18-58gif.gif)
Author
Owner

@zadjii-msft commented on GitHub (Dec 3, 2020):

That's bizarre - @DHowett help me figure this one out?

@zadjii-msft commented on GitHub (Dec 3, 2020): That's bizarre - @DHowett help me figure this one out?
Author
Owner

@Venipa commented on GitHub (Dec 7, 2020):

after upgrading to Windows 10 20h2 (19042.662) this issue dissappeared
@zadjii-msft

@Venipa commented on GitHub (Dec 7, 2020): after upgrading to Windows 10 20h2 (19042.662) this issue dissappeared @zadjii-msft
Author
Owner

@zadjii-msft commented on GitHub (Dec 7, 2020):

Thanks for following up. That is super weird. I'm glad it went away! Hopefully your discovery will be helpful for future people who hit this.

@zadjii-msft commented on GitHub (Dec 7, 2020): Thanks for following up. That is super weird. I'm glad it went away! Hopefully your discovery will be helpful for future people who hit this.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#11635