Saving settings with removed default profiles creates them as empty objects #14879

Open
opened 2026-01-31 04:22:03 +00:00 by claunia · 0 comments
Owner

Originally created by @lhecker on GitHub (Aug 16, 2021).

Originally assigned to: @lhecker on GitHub.

Steps to reproduce

  • Remove a default profile, for instance cmd.exe
  • Hit Save in the settings UI

Expected behavior

A new section is created:

{
    "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
    "hidden": false,
    "name": "Command Prompt"
},

Actual behavior

A new section is created:

{
    "hidden": true
},

Proposed solution

CascadiaSettings v3 Remove the usage of raw JSON handling from CascadiaSettings and slim down the class and its relatives. It's too hard to understand when and how layering issues happen and fixing them often feels like hacks. With reduced cruft it should be easier to prevent bugs like this categorically.

Alternatively we could convert the two builtin profiles into generators.

Originally created by @lhecker on GitHub (Aug 16, 2021). Originally assigned to: @lhecker on GitHub. # Steps to reproduce * Remove a default profile, for instance `cmd.exe` * Hit Save in the settings UI # Expected behavior A new section is created: ```json { "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}", "hidden": false, "name": "Command Prompt" }, ``` # Actual behavior A new section is created: ```json { "hidden": true }, ``` # Proposed solution ~CascadiaSettings v3~ Remove the usage of raw JSON handling from CascadiaSettings and slim down the class and its relatives. It's too hard to understand when and how layering issues happen and fixing them often feels like hacks. With reduced cruft it should be easier to prevent bugs like this categorically. Alternatively we could convert the two builtin profiles into generators.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#14879