Skip to content

Add support for DSCv3 in configuration PowerShell modules #5470

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 9 commits into from
May 27, 2025

Conversation

yao-msft
Copy link
Contributor

@yao-msft yao-msft commented May 20, 2025

Microsoft Reviewers: Open in CodeFlow

@yao-msft yao-msft requested a review from a team as a code owner May 20, 2025 23:05
@@ -10,7 +10,7 @@

// Forcibly set the target and supported platforms due to the internal build setup.
// Keep in sync with project versions.
[assembly: TargetPlatform("Windows10.0.22000.0")]
[assembly: TargetPlatform("Windows10.0.26100.0")]
Copy link
Member

Choose a reason for hiding this comment

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

I feel like there was a reason that I didn't update that... but now I'm not remembering it.


await installDSCv3.InvokeAsync();

if (installDSCv3.HadErrors)
Copy link
Member

Choose a reason for hiding this comment

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

Install-WinGetPackage does not produce an error on failed install. The result object must be inspected.

I'm not sure of the "correct" PowerShell design, but maybe one of:

  1. A new cmdlet like Validate-WinGetPackageInstall that throws if the install failed
  2. A new parameter like -ThrowOnFailure
  3. A breaking change to throw on failure (maybe with a parameter to not)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I can change the script to inspect the result object.

@yao-msft yao-msft merged commit 6430ee2 into microsoft:master May 27, 2025
9 checks passed
@yao-msft yao-msft deleted the dscv3ps branch May 27, 2025 19:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants