Execution Alias for Preview not working from Run Dialog box #18472

Closed
opened 2026-01-31 06:15:09 +00:00 by claunia · 9 comments
Owner

Originally created by @rog1039 on GitHub (Sep 15, 2022).

Windows Terminal version

1.16.2523.0

Windows build number

19044.2006

Other Software

No response

Steps to reproduce

Change execution alias in settings app from WindowsTerminal to WindowsTerminalPreview
Then type wt into the run dialox box.

Expected Behavior

I would then expect windows terminal preview to open.

Actual Behavior

I receive this message instead.
image

I can open windows terminal preview by just searching in the start menu for terminal preview. If I switch the alias back to the non-preview terminal then the wt alias will open the regular release of terminal. It is just when I switch the alias to the preview and then try to open the preview with wt from the run dialog box that I get the error. Interestingly, I can open the preview terminal by typing wt into an already open terminal preview window and it will work fine. Just seems to be opening wt from the run dialog box. In fact, I can even type wt into the command line (cmd.exe) and it will open terminal preview just fine. Seems there is something special about the run dialog box??

Thanks!
Paul

Originally created by @rog1039 on GitHub (Sep 15, 2022). ### Windows Terminal version 1.16.2523.0 ### Windows build number 19044.2006 ### Other Software _No response_ ### Steps to reproduce Change execution alias in settings app from WindowsTerminal to WindowsTerminalPreview Then type ```wt``` into the run dialox box. ### Expected Behavior I would then expect windows terminal preview to open. ### Actual Behavior I receive this message instead. ![image](https://user-images.githubusercontent.com/5702706/190421645-ab53deed-3f32-4b56-a56e-d99affa12464.png) I can open windows terminal preview by just searching in the start menu for terminal preview. If I switch the alias back to the non-preview terminal then the ```wt``` alias will open the regular release of terminal. It is just when I switch the alias to the preview and then try to open the preview with wt from the run dialog box that I get the error. Interestingly, I can open the preview terminal by typing ```wt``` into an already open terminal preview window and it will work fine. Just seems to be opening wt from the run dialog box. In fact, I can even type ```wt``` into the command line (cmd.exe) and it will open terminal preview just fine. Seems there is something special about the run dialog box?? Thanks! Paul
Author
Owner

@rog1039 commented on GitHub (Sep 15, 2022):

Also, just realized the title of the dialog box suggests it is trying to openan older terminal version, 1.24.2281.0? Not sure where that is coming from and/or why the run box would try to open that version when all other uses of wt open the preview terminal without issue.

@rog1039 commented on GitHub (Sep 15, 2022): Also, just realized the title of the dialog box suggests it is trying to openan older terminal version, 1.24.2281.0? Not sure where that is coming from and/or why the run box would try to open that version when all other uses of ```wt``` open the preview terminal without issue.
Author
Owner

@lhecker commented on GitHub (Sep 16, 2022):

I wonder if this is related to #9452.

@lhecker commented on GitHub (Sep 16, 2022): I wonder if this is related to #9452.
Author
Owner

@rog1039 commented on GitHub (Sep 16, 2022):

Well, through that link and then through other related links I was able to come to a workaround.

I read the issue #9452 which I then followed to several other issues, eventually landing here: https://github.com/microsoft/terminal/issues/12534 and https://github.com/microsoft/terminal/issues/12249

My permissions (which I haven't touched) looked exactly like they should be according to: https://github.com/microsoft/terminal/issues/12534#issuecomment-1048851877

I did perform the takeown and cacls anyway as suggested here, which had no effect.
https://github.com/microsoft/terminal/issues/12534#issuecomment-1051338640

I then looked at this comment: https://github.com/microsoft/terminal/issues/7081#issuecomment-1065833836 about registry settings. In my case the registry looked like this:
image
I thought this was interesting because it references that weird older version of terminal 1.24.2281.0 in the registry. I tried deleting the wt.exe key in its entirety but that had no effect whatsoever.

The comment linked to from #7081 suggested just changing the paths from C:\Program Files\WindowsApps to something in your local app data folder so I did that. My registry now looks like this:
image

And now wt.exe from the Run Dialog box will open the preview version of Windows Terminal. However, in making this change, App execution aliases in the Settings app no longer works. Meaning if I set the alias for Regular Terminal to On then it still opens the preview terminal. If I set the alias to Terminal Preview it of course opens the preview terminal as well. Best I can tell, by setting that registry value, App execution aliases no longer do anything. I can even set both aliases to Off and wt.exe will still open terminal preview. So that registry entry must take precedence over the app execution alias setting.

So this workaround does allow me to open the preview terminal now by using wt.exe from the command line but we broke app execution aliases in the process. Not sure what is going on here, there seem to be lot of issues similar/tangentially related to mine. Probably more an issue inside windows (and more likely something with the Store/UWP/whatever they call it now) than in terminal. Hopefully they can fix some of these bugs!

Thanks,
Paul

@rog1039 commented on GitHub (Sep 16, 2022): Well, through that link and then through other related links I was able to come to a workaround. I read the issue #9452 which I then followed to several other issues, eventually landing here: https://github.com/microsoft/terminal/issues/12534 and https://github.com/microsoft/terminal/issues/12249 My permissions (which I haven't touched) looked exactly like they should be according to: https://github.com/microsoft/terminal/issues/12534#issuecomment-1048851877 I did perform the takeown and cacls anyway as suggested here, which had no effect. https://github.com/microsoft/terminal/issues/12534#issuecomment-1051338640 I then looked at this comment: https://github.com/microsoft/terminal/issues/7081#issuecomment-1065833836 about registry settings. In my case the registry looked like this: ![image](https://user-images.githubusercontent.com/5702706/190666363-3d54e71f-fa13-42ec-8ab8-e90d5bd3a0ff.png) I thought this was interesting because it references that weird older version of terminal 1.24.2281.0 in the registry. I tried deleting the wt.exe key in its entirety but that had no effect whatsoever. The comment linked to from #7081 suggested just changing the paths from ```C:\Program Files\WindowsApps``` to something in your local app data folder so I did that. My registry now looks like this: ![image](https://user-images.githubusercontent.com/5702706/190667084-83109c13-3bf8-43db-a738-2f9f245aa7d5.png) And now wt.exe from the Run Dialog box will open the preview version of Windows Terminal. However, in making this change, ```App execution aliases``` in the Settings app no longer works. Meaning if I set the alias for Regular Terminal to On then it still opens the preview terminal. If I set the alias to Terminal Preview it of course opens the preview terminal as well. Best I can tell, by setting that registry value, ```App execution aliases``` no longer do anything. I can even set both aliases to Off and wt.exe will still open terminal preview. So that registry entry must take precedence over the app execution alias setting. So this workaround does allow me to open the preview terminal now by using wt.exe from the command line but we broke app execution aliases in the process. Not sure what is going on here, there seem to be lot of issues similar/tangentially related to mine. Probably more an issue inside windows (and more likely something with the Store/UWP/whatever they call it now) than in terminal. Hopefully they can fix some of these bugs! Thanks, Paul
Author
Owner

@lhecker commented on GitHub (Sep 16, 2022):

Maybe it's a naive suggestion, but maybe it will fix the issue if you backup your settings.json and uninstall both Terminal variants (normal and Preview) and reinstall Windows Terminal Preview?

@lhecker commented on GitHub (Sep 16, 2022): Maybe it's a naive suggestion, but maybe it will fix the issue if you backup your settings.json and uninstall both Terminal variants (normal and Preview) and reinstall Windows Terminal Preview?
Author
Owner

@rog1039 commented on GitHub (Sep 16, 2022):

After uninstalling both applications, I was able to install the regular terminal but the store gives me an error when installing the preview. I receive Code: 0x80070005

@rog1039 commented on GitHub (Sep 16, 2022): After uninstalling both applications, I was able to install the regular terminal but the store gives me an error when installing the preview. I receive Code: 0x80070005
Author
Owner

@lhecker commented on GitHub (Sep 16, 2022):

0x80070005 is "Access is denied." (ERROR_ACCESS_DENIED). This is an issue which is about the same failure code: #12001

@lhecker commented on GitHub (Sep 16, 2022): `0x80070005` is "Access is denied." (`ERROR_ACCESS_DENIED`). This is an issue which is about the same failure code: #12001
Author
Owner

@rog1039 commented on GitHub (Sep 16, 2022):

Figured it was something like that. Unfortunately, that user had no luck fixing the issue and just blew away his profile. Not in a position to do that right now, but may end up just reinstalling Windows soon. It's about that time anyway.

@rog1039 commented on GitHub (Sep 16, 2022): Figured it was something like that. Unfortunately, that user had no luck fixing the issue and just blew away his profile. Not in a position to do that right now, but may end up just reinstalling Windows soon. It's about that time anyway.
Author
Owner

@zadjii-msft commented on GitHub (Nov 8, 2022):

We might be stuck on our end. Can you file feedback on
image/?

That might help get this to the right folks to investigate

@zadjii-msft commented on GitHub (Nov 8, 2022): We might be stuck on our end. Can you file feedback on ![image](https://user-images.githubusercontent.com/18356694/200627616-19937365-317d-4d08-9cb9-42f0b6efd992.png)/? That might help get this to the right folks to investigate
Author
Owner

@ghost commented on GitHub (Nov 12, 2022):

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.

@ghost commented on GitHub (Nov 12, 2022): This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for **4 days**. It will be closed if no further activity occurs **within 3 days of this comment**.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#18472