Azure / Azure/azure-powershell

Get-AzFirewallPolicyRuleCollectionGroup not using resourceid parameter

Open
#22,312 9 comments 4 reactions 0 assignees View on GitHub
act-quality-productivity-squad bug customer-reported Network - Firewall Service Attention
Dominant language
C#
Stars
4.8k
Forks
4.3k
Avg merge
3d 14h
Merged PRs (30d)
54

Description

### Description

`Get-AzFirewallPolicyRuleCollectionGroup` source code has the parameter for resourceid but not used in the `executecmdlet` . When I run the cmdlet, returns nothing but accepts the Resource ID string.

### Issue script & Debug output

```PowerShell
PS> $DebugPreference='Continue'
PS> Get-AzFirewallPolicyRuleCollectionGroup -ResourceId ""
DEBUG: 14:51:35 - GetAzureFirewallPolicyRuleCollectionGroupCommand begin processing with ParameterSet 'GetByResourceIdParameterSet'.
DEBUG: 14:51:35 - using account id ''...
DEBUG: 14:51:35 - [ConfigManager] Got nothing from [DisplayBreakingChangeWarning], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 14:51:35 - [ConfigManager] Got nothing from [DisplayRegionIdentified], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: AzureQoSEvent: Module: Az.Network:6.1.0; CommandName: Get-AzFirewallPolicyRuleCollectionGroup; PSVersion: 7.3.5; IsSuccess: True; Duration: 00:00:00.0018991
DEBUG: 14:51:35 - [ConfigManager] Got nothing from [EnableDataCollection], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 14:51:35 - GetAzureFirewallPolicyRuleCollectionGroupCommand end processing.
```

### Environment data

```PowerShell
PS> $PSVersionTable

Name Value
---- -----
PSVersion 7.3.5
PSEdition Core
GitCommitId 7.3.5
OS Microsoft Windows 10.0.19045
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
```

### Module versions

```PowerShell
PS > Get-Module Az*

ModuleType Version PreRelease Name ExportedCommands
---------- ------- ---------- ---- ----------------
Script 2.12.4 Az.Accounts {Add-AzEnvironment, Clear-AzConfig, Clear-AzContext, Clear-AzDefault…}
Script 6.1.0 Az.Network {Add-AzApplicationGatewayAuthenticationCertificate, Add-AzApplicationGatewayBackendAddressPool, Add-AzApplicationGatewayBackendHttpSetting…
```

### Error output

```PowerShell
PS> Resolve-AzError
DEBUG: 14:51:46 - ResolveError begin processing with ParameterSet 'AnyErrorParameterSet'.
DEBUG: 14:51:46 - using account id ''...
DEBUG: 14:51:46 - [ConfigManager] Got nothing from [DisplayBreakingChangeWarning], Module = [], Cmdlet = []. Returning default value [True].

DEBUG: 14:51:46 - [ConfigManager] Got nothing from [DisplayRegionIdentified], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: AzureQoSEvent: Module: Az.Accounts:2.12.4; CommandName: Resolve-AzError; PSVersion: 7.3.5; IsSuccess: True; Duration: 00:00:00.0008613
DEBUG: 14:51:46 - [ConfigManager] Got nothing from [EnableDataCollection], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 14:51:46 - ResolveError end processing.
```

Contributor guide

Open the contributing guide

Research direction

Start at the Get-AzFirewallPolicyRuleCollectionGroup entry point and inspect the ResourceId parameter set and its ExecuteCmdlet path. Reproduce the command with the ResourceId shown in the issue, then verify that the cmdlet returns the requested rule collection group instead of nothing.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp, powershell
Domain
cli, cloud
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.