-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Transition ActionPreference.Suspend enumeration value into a non-supported, reserved state, and remove restriction on using ActionPreference.Ignore in preference variables #10317
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
Conversation
iSazonov
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with one comment.
PaulHigin
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
@PowerShell/powershell-committee the decision here is what to do about removing a workflow specific value from the existing public enum. One option is to mark it obsolete. |
|
@PowerShell/powershell-committee reviewed this, we discussed removal, using |
|
To address the committee review feedback, I just made the following changes:
I'll also update the OP accordingly. |
src/System.Management.Automation/engine/ArgumentTypeConverterAttribute.cs
Show resolved
Hide resolved
src/System.Management.Automation/engine/ArgumentTypeConverterAttribute.cs
Show resolved
Hide resolved
|
Just FYI in case it wasn't clear: I updated this PR once #8205 was merged into PowerShell, so this PR is one again ready for review/merge. Two of the three Codacy issues are incorrect (looks like it needs to be updated for modern syntax), and the third one is related to a Pester test and will be ignored. |
|
@PaulHigin Could you please update your review (we have new commits)? |
|
FYI, I will not be making changes based on the Codacy review because one of the issues is a false positive, and the other two are incorrect. This PR is ready for review by other reviewers. |
|
@SteveL-MSFT PowerShell Committee request was addressed. Can we merge? |
test/powershell/Modules/Microsoft.PowerShell.Management/Test-Connection.Tests.ps1
Outdated
Show resolved
Hide resolved
…orted, reserved state, and remove restriction on using ActionPreference.Ignore in preference variables (PowerShell#10317)
|
🎉 Handy links: |
PR Summary
As part of the cleanup of workflow code, this PR does the following:
ActionPreference.Suspendenumeration value as not supported and reserved for future use.ActionPreference.Suspendsuch that using that value results in appropriate error messages.ActionPreference.Suspendto ensure that it is generating the errors we expect when it is used.ActionPreference.Ignore(see this discussion in issue 4348). This change is made as part of this PR because it is in the exact same body of code, and it makes sense to include it here.PR Context
See issue #9570.
PR Checklist
.h,.cpp,.cs,.ps1and.psm1files have the correct copyright headerWIP:or[ WIP ]to the beginning of the title (theWIPbot will keep its status check atPendingwhile the prefix is present) and remove the prefix when the PR is ready.