FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[release/v7.6.10] Use `GetCurrentPackageFamilyNameNative` API instead of path matching to detect MSIX installation by daxian-dbw · Pull Request #28313 · PowerShell/PowerShell · GitHub

Repository navigation

[release/v7.6.10] Use GetCurrentPackageFamilyNameNative API instead of path matching to detect MSIX installation - #28313

Merged
Dongbo Wang (daxian-dbw) merged 1 commit into
PowerShell:release/v7.6.10from
daxian-dbw:backport/release/v7.6.10/28029-29a743d40
Nov 4, 2026
Merged

Dongbo Wang (daxian-dbw) merged 1 commit into
PowerShell:release/v7.6.10from
daxian-dbw:backport/release/v7.6.10/28029-29a743d40

Conversation

Copy link
Copy Markdown
Member

Backport of #28029 to release/v7.6.10

Triggered by Dongbo Wang (@daxian-dbw) on behalf of Dongbo Wang (@daxian-dbw)

Original CL Label: CL-General

/cc @PowerShell/powershell-maintainers

Impact

REQUIRED: Choose either Tooling Impact or Customer Impact (or both). At least one checkbox must be selected.

Tooling Impact

  • Required tooling change
  • Optional tooling change (include reasoning)

Customer Impact

  • Customer reported
  • Found internally

Improves handling of the customer-reported MSIX/PATH issue discussed in #27782. Uses native package identity detection instead of installation-path matching to select the stable execution-alias directory, and compares Windows process names case-insensitively so mixed-case launch paths are handled correctly.

Regression

REQUIRED: Check exactly one box.

  • Yes
  • No

This is not a regression.

Testing

The original PR reports validation with the MSIX bundle produced by its build. Backport commit ce96a4c cherry-picked without conflicts and the working tree is clean. Local tests were not run; backport CI must pass before merge.

Risk

REQUIRED: Check exactly one box.

  • High
  • Medium
  • Low

Changes startup PATH handling and adds Windows native interop. Changes are scoped to installation detection and Windows process-name comparison; the prerequisite MSIX PATH fix is already backported.

Dongbo Wang (daxian-dbw) added the CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log label Nov 3, 2026
Copilot AI balanced review requested due to automatic review settings November 3, 2026 22:58

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

🔵 Needs a closer look

The Windows startup PATH backport lacks release-branch validation of MSIX execution-alias resolution, unpackaged startup, and unavailable-native-API fallback; documented upstream testing does not establish those runtime results.

No open issues 🎉

What changed in this PR

Backports #28029 to release/v7.6.10, refining the existing MSIX startup PATH fix by detecting package identity through a Windows API rather than installation-path matching.

Changes:

  • Adds native package-family lookup with cached installation detection.
  • Uses the package family name to select the stable execution-alias directory for PATH.
  • Makes Windows executable-name comparisons case-insensitive while preserving Unix behavior.
File Description
src/​System.Management.Automation/​engine/​Utils.cs Caches MSIX identity detection and the package family name.
src/​System.Management.Automation/​engine/​Interop/​Windows/​GetCurrentPackageFamilyName.cs Adds a native package-family lookup wrapper.
src/​Microsoft.PowerShell.ConsoleHost/​host/​msh/​ConsoleHost.cs Replaces path-based detection and handles mixed-case Windows executable names.

Review effort: Balanced

Justin Chung (jshigetomi) left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Reviewed as a faithful backport; no blocking issues found.

Dongbo Wang (daxian-dbw) merged commit 3640dc0 into PowerShell:release/v7.6.10 Nov 4, 2026
36 checks passed
Dongbo Wang (daxian-dbw) deleted the backport/release/v7.6.10/28029-29a743d40 branch November 4, 2026 17:22
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL