Skip to content

During session save, use the profile's GUID rather than its Name #19113

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 9, 2025

Conversation

DHowett
Copy link
Member

@DHowett DHowett commented Jul 9, 2025

This will prevent Terminal from erroneously selecting a hidden (deleted, disabled or otherwise) profile of the same name during restoration and subsequently using the wrong settings.

I am not certain why we used the name at all!

Closes #19105

This will prevent Terminal from erroneously selecting a hidden (deleted,
disabled or otherwise) profile of the same name during restoration and
subsequently using the wrong settings.

I am not certain why we used the name at all!

Closes #19105
@DHowett
Copy link
Member Author

DHowett commented Jul 9, 2025

@Frulfump I tested this one out locally with two profiles named PowerShell and two vastly different configurations. It seems to have worked!

Copy link
Member

@lhecker lhecker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That... works?

@DHowett
Copy link
Member Author

DHowett commented Jul 9, 2025

That... works?

Yep! NewTerminalArgs is how the action works, and we wanted to make it possible for users to use either names or GUIDs in their action object. It's about as terrible as you might imagine. This is one of the reasons I am so staunchly opposed to using actions as the session restoration AND HANDOFF currency, but that ship sailed/caught fire/sank.

@DHowett DHowett merged commit c4fbb58 into main Jul 9, 2025
19 checks passed
@DHowett DHowett deleted the dev/duhowett/fix19105 branch July 9, 2025 20:42
@DHowett DHowett moved this from To Cherry Pick to Cherry Picked in 1.22 Servicing Pipeline Jul 29, 2025
@DHowett DHowett moved this from To Cherry Pick to Cherry Picked in 1.23 Servicing Pipeline Jul 29, 2025
DHowett added a commit that referenced this pull request Jul 29, 2025
)

This will prevent Terminal from erroneously selecting a hidden (deleted,
disabled or otherwise) profile of the same name during restoration and
subsequently using the wrong settings.

I am not certain why we used the name at all!

Closes #19105

(cherry picked from commit c4fbb58)
Service-Card-Id: PVTI_lADOAF3p4s4AxadtzgcbMe0
Service-Version: 1.23
DHowett added a commit that referenced this pull request Jul 29, 2025
)

This will prevent Terminal from erroneously selecting a hidden (deleted,
disabled or otherwise) profile of the same name during restoration and
subsequently using the wrong settings.

I am not certain why we used the name at all!

Closes #19105

(cherry picked from commit c4fbb58)
Service-Card-Id: PVTI_lADOAF3p4s4AmhmQzgcbMe4
Service-Version: 1.22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Cherry Picked
Status: Cherry Picked
Development

Successfully merging this pull request may close these issues.

Session restoration can lead to the wrong profile being selected on restore (saved by name rather than guid)
2 participants