Fix PSSA rule violation in New-CcmDeploymentStep
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 65/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- powershell
- Domain
- tooling
Research direction
Start in src/Public/New-CCMDeploymentStep.ps1 at the parameter declaration around lines 110-112, then inspect how that parameter is passed to CCM. Rename the switch as proposed and verify the default behavior and PSSA compliance, including any relevant module tests if present.
Written by the indexing model from the issue text.
Description
What You Are Seeing?
This parameter declaration breaks the PSSA rule PSAvoidDefaultValueSwitchParameter because the switch defaults to $true:
What is Expected?
Switch parameters should never default to $true in PowerShell as it is cumbersome and counterintuitive to set them to $false when needed.
I suggest renaming the switch to -ContinueOnError instead, so that the ordinary and expected default of $false for a switch parameter behaves as expected. We will then need to invert the value before passing it to CCM.
How Did You Get This To Happen? (Steps to Reproduce)
I opened the file for editing in VS Code with the PowerShell extension enabled.
System Details
N/A
Output Log
N/A
- Dominant language
- PowerShell
- Stars
- 7
- Forks
- 11
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from chocolatey/ChocoCCM
-
0 - Backlog Enhancement
Difficulty 5/5 Over a week Newbie friendliness 25/100
chocolatey/ChocoCCM#72 ·
-
New/Set-CcmDeploymentStep should have parameters for -AllowPrerelease and -Version for basic steps Open0 - Backlog Enhancement
Difficulty 3/5 1-2 days Newbie friendliness 48/100
chocolatey/ChocoCCM#71 ·
-
0 - Backlog Bug
Difficulty 2/5 1-3 hours Newbie friendliness 48/100
chocolatey/ChocoCCM#68 ·
-
0 - Backlog Bug
Difficulty 4/5 3-5 days Newbie friendliness 25/100
chocolatey/ChocoCCM#66 ·
-
2 - Working Enhancement
chocolatey/ChocoCCM#63 · 1 assignee ·
All issues in chocolatey/ChocoCCM
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
hemilabs/ui-monorepo#2332 ·
-
Help-Wanted Needs-Triage Package-Update
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
microsoft/winget-pkgs#438662 ·
-
priority: p3
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
googleapis/librarian#7636 ·
-
bug good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
olcf/olcf-test-harness#278 · 1 comment ·