Skip to content

Create Az.CloudHsm Module for 2025-03-31 #27947

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

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

emmeliaAra
Copy link
Member

Description

Mandatory Checklist

  • SHOULD update ChangeLog.md file(s) appropriately
    • Update src/{{SERVICE}}/{{SERVICE}}/ChangeLog.md.
      • A snippet outlining the change(s) made in the PR should be written under the ## Upcoming Release header in the past tense.
    • Should not change ChangeLog.md if no new release is required, such as fixing test case only.
  • SHOULD regenerate markdown help files if there is cmdlet API change. Instruction
  • SHOULD have proper test coverage for changes in pull request.
  • SHOULD NOT adjust version of module manually in pull request

@Copilot Copilot AI review requested due to automatic review settings June 12, 2025 14:38
Copy link

Thanks for your contribution! The pull request validation has started. Please revisit this comment for updated status.

@emmeliaAra emmeliaAra changed the title Initial commit Az.CloudHsm 2025-03-31 Create Az.CloudHsm Module for 2025-03-31 Jun 12, 2025
Copilot

This comment was marked as outdated.

@jkapil jkapil requested a review from Copilot June 12, 2025 23:19
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR scaffolds the new Az.CloudHsm PowerShell module targeting the 2025-03-31 API version.

  • Added autogenerated comment-based help files for core cmdlets (New, Get, Backup, Remove).
  • Introduced custom script implementations for each cmdlet under the custom/ folder.
  • Updated module packaging/configuration (AutoRest directives, AssemblyInfo.cs, .gitignore, .gitattributes, NuGet.Config).

Reviewed Changes

Copilot reviewed 82 out of 82 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/CloudHsm/CloudHsm.Autorest/docs/Remove-AzCloudHsm.md Help content for the Remove-AzCloudHsm cmdlet
src/CloudHsm/CloudHsm.Autorest/docs/New-AzCloudHsm.md Help content for the New-AzCloudHsm cmdlet
src/CloudHsm/CloudHsm.Autorest/docs/Get-AzCloudHsm.md Help content for the Get-AzCloudHsm cmdlet
src/CloudHsm/CloudHsm.Autorest/docs/Backup-AzCloudHsm.md Help content for the Backup-AzCloudHsm cmdlet
src/CloudHsm/CloudHsm.Autorest/docs/README.md Overview of docs generation process
src/CloudHsm/CloudHsm.Autorest/custom/*.ps1 Script-based implementations of all core cmdlets
src/CloudHsm/CloudHsm.Autorest/README.md AutoRest configuration and module-level documentation
src/CloudHsm/CloudHsm.Autorest/Properties/AssemblyInfo.cs Assembly metadata for module versioning
src/CloudHsm/CloudHsm.Autorest/.gitignore & .gitattributes Build and source-control settings
NuGet.Config Added OneBranch-Consumption feed
Comments suppressed due to low confidence (1)

src/CloudHsm/CloudHsm.Autorest/docs/Get-AzCloudHsm.md:92

  • [nitpick] Renumber this heading to "Example 3" to avoid duplicating "Example 2" in the examples section.
### Example 2:  Get a Cloud HSM in a resource group 

@vidai-msft
Copy link
Contributor

/azp run

Copy link
Contributor

Azure Pipelines will not run the associated pipelines, because the pull request was updated after the run command was issued. Review the pull request again and issue a new run command.

Copy link
Contributor

@vidai-msft vidai-msft left a comment

Choose a reason for hiding this comment

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

Please remove the test stubs whose cmdlets are removed or hidden.

Copy link

This PR was labeled "needs-revision" because it has unresolved review comments or CI failures.
Please resolve all open review comments and make sure all CI checks are green. Refer to our guide to troubleshoot common CI failures.

@vidai-msft
Copy link
Contributor

/azp run

Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@emmeliaAra
Copy link
Member Author

/azp run

Copy link
Contributor

Commenter does not have sufficient privileges for PR 27947 in repo Azure/azure-powershell

@emmeliaAra emmeliaAra requested a review from vidai-msft June 16, 2025 13:08
@vidai-msft
Copy link
Contributor

/azp run

Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@emmeliaAra
Copy link
Member Author

Hi @vidai-msft, the checks are failing with the error below. Can you please help with the steps to resolve it ?

Write-Error: Unhandled exception. System.Management.Automation.CmdletInvocationException: The member 'FormatsToProcess' in the module manifest is not valid: Cannot find path 'D:\a_work\1\s\artifacts\Debug\Az.CloudHsm\CloudHsm.Autorest/Az.CloudHsm.format.ps1xml' because it does not exist.. Verify that a valid value is specified for this field in the 'D:\a_work\1\s\artifacts\Debug\Az.CloudHsm\Az.CloudHsm.psd1' file.
---> System.ArgumentException: The member 'FormatsToProcess' in the module manifest is not valid: Cannot find path 'D:\a_work\1\s\artifacts\Debug\Az.CloudHsm\CloudHsm.Autorest/Az.CloudHsm.format.ps1xml' because it does not exist.. Verify that a valid value is specified for this field in the 'D:\a_work\1\s\artifacts\Debug\Az.CloudHsm\Az.CloudHsm.psd1' file.
at System.Management.Automation.MshCommandRuntime.ThrowTerminatingError(ErrorRecord errorRecord)
--- End of inner exception stack trace ---
at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable input)
at System.Management.Automation.Runspaces.Pipeline.Invoke()
at System.Management.Automation.PowerShell.Worker.ConstructPipelineAndDoWork(Runspace rs, Boolean performSyncInvoke)
at System.Management.Automation.PowerShell.Worker.CreateRunspaceIfNeededAndDoWork(Runspace rsToUse, Boolean isSync)
at System.Management.Automation.PowerShell.CoreInvokeHelper[TInput,TOutput](PSDataCollection1 input, PSDataCollection1 output, PSInvocationSettings settings)
at System.Management.Automation.PowerShell.CoreInvoke[TInput,TOutput](PSDataCollection1 input, PSDataCollection1 output, PSInvocationSettings settings)
at System.Management.Automation.PowerShell.CoreInvoke[TOutput](IEnumerable input, PSDataCollection1 output, PSInvocationSettings settings) at System.Management.Automation.PowerShell.Invoke(IEnumerable input, PSInvocationSettings settings) at System.Management.Automation.PowerShell.Invoke() at StaticAnalysis.BreakingChangeAnalyzer.BreakingChangeAnalyzer.Analyze(IEnumerable1 cmdletProbingDirs, Func2 directoryFilter, Func2 cmdletFilter, IEnumerable1 modulesToAnalyze) in D:\a\_work\1\s\tools\StaticAnalysis\BreakingChangeAnalyzer\BreakingChangeAnalyzer.cs:line 138 at StaticAnalysis.BreakingChangeAnalyzer.BreakingChangeAnalyzer.Analyze(IEnumerable1 cmdletProbingDirs, IEnumerable`1 modulesToAnalyze) in D:\a_work\1\s\tools\StaticAnalysis\BreakingChangeAnalyzer\BreakingChangeAnalyzer.cs:line 66
at StaticAnalysis.Program.Main(String[] args) in D:\a_work\1\s\tools\StaticAnalysis\Program.cs:line 189
Help record Backup-AzCloudHsm has no cmdlet.
Help record Get-AzCloudHsm has no cmdlet.
Help record New-AzCloudHsm has no cmdlet.
Help record Remove-AzCloudHsm has no cmdlet.
Help record Restore-AzCloudHsm has no cmdlet.
Help record Update-AzCloudHsm has no cmdlet.

@vidai-msft
Copy link
Contributor

/azp run

Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

# - (this-folder)/relative-path-to-your-local-readme.md

input-file:
- $(this-folder)/../../../../azure-rest-api-specs-myFork/specification/hardwaresecuritymodules/resource-manager/Microsoft.HardwareSecurityModules/stable/2025-03-31/cloudHsm.json
Copy link
Contributor

Choose a reason for hiding this comment

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

$(this-folder) is pointing to a local file. This is only used for development when swagger is not ready. However, it must be updated to a remote swagger file when swagger is ready. That is also the cause why CI failed. Please update the value if swagger is ready and then try again.

Copy link

‼️ DO NOT MERGE THIS PR ‼️
This PR was labeled "Do Not Merge" because it contains code change that cannot be merged. Please contact the reviewer for more information.

Copy link

This PR was labeled "needs-revision" because it has unresolved review comments or CI failures.
Please resolve all open review comments and make sure all CI checks are green. Refer to our guide to troubleshoot common CI failures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants