If settings.json in portable settings folder (or folder itself) is not writeable WT will crash if you try to save settings #23258

Closed
opened 2026-01-31 08:37:00 +00:00 by claunia · 3 comments
Owner

Originally created by @PGomersall on GitHub (May 14, 2025).

Originally assigned to: @carlos-zamora on GitHub.

Windows Terminal version

1.22.250314001 Portable (probably other versions as well)

Windows build number

10.0.26100.4061

Other Software

N\A

Steps to reproduce

Open settings UI, make a change click save > WT crashes

Expected Behavior

An error should be raised if settings.json is not writeable, but WT should not crash.

Actual Behavior

WT Crashes. If folder is writeable but not the settings.json file a settings.json.tmp is created

Originally created by @PGomersall on GitHub (May 14, 2025). Originally assigned to: @carlos-zamora on GitHub. ### Windows Terminal version 1.22.250314001 Portable (probably other versions as well) ### Windows build number 10.0.26100.4061 ### Other Software N\A ### Steps to reproduce Open settings UI, make a change click save > WT crashes ### Expected Behavior An error should be raised if settings.json is not writeable, but WT should not crash. ### Actual Behavior WT Crashes. If folder is writeable but not the settings.json file a settings.json.tmp is created
Author
Owner

@Zeroes1 commented on GitHub (May 19, 2025):

canary terminal-1.24.1351.0 same.

@Zeroes1 commented on GitHub (May 19, 2025): canary terminal-1.24.1351.0 same.
Author
Owner

@DHowett commented on GitHub (May 28, 2025):

Thanks! I could have sworn we had a duplicate for this, but it appears that we don't. Congrats!

Though: why is it not writable? 🙃

@DHowett commented on GitHub (May 28, 2025): Thanks! I could have sworn we had a duplicate for this, but it appears that we don't. Congrats! Though: why is it not writable? 🙃
Author
Owner

@PGomersall commented on GitHub (May 28, 2025):

Though: why is it not writable?

@DHowett
I had a script to automate updating and or creation of the portable in C:\WT which runs as system. On some systems the default permissions on C:\ and therefore the inherited C:\WT did not give users more than read and execute. I added code in my script to deal with this, but wt should not crash regardless trying to write to the settings file that is effectively locked, hence my bug ticket.

@PGomersall commented on GitHub (May 28, 2025): > Though: why is it not writable? @DHowett I had a script to automate updating and or creation of the portable in C:\WT which runs as system. On some systems the default permissions on C:\ and therefore the inherited C:\WT did not give users more than read and execute. I added code in my script to deal with this, but wt should not crash regardless trying to write to the settings file that is effectively locked, hence my bug ticket.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#23258