microsoft / vscode-azureresourcegroups

VS Code extension for managing Azure resources.
https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azureresourcegroups
MIT License
52 stars 28 forks source link

Cannot retrieve resources under each subscription #773

Closed JLZ1783 closed 10 months ago

JLZ1783 commented 10 months ago

Does this occur consistently? Recently occurring for 1 or more subscriptions but not all. ( I do have appropriate permissions to view resources and can access in the portal). Repro steps:

  1. Click on

Action: subscriptionItem.getChildren Error type: Error Error Message: Internal error: Expected value to be neither null nor undefined: resourceGroup for grouping item

Version: 0.8.0 OS: win32 OS Release: 10.0.19044 Product: Visual Studio Code Product Version: 1.84.2 Language: en

Call Stack ``` nonNullValue extension.bundle.js:2:787434 groupingItemFactory extension.bundle.js:2:1536309 extension.bundle.js:2:1534158extension.bundle.js:2:1534158 groupBy extension.bundle.js:2:1534144 AzureResourceGroupingManager.groupByResourceGroup extension.bundle.js:2:1535976 AzureResourceGroupingManager.groupResources extension.bundle.js:2:1534944 SubscriptionItem. extension.bundle.js:2:1532784 fulfilled extension.bundle.js:2:1531548 ```
nturinski commented 10 months ago

Sorry that you're running into this issue. It seems like one of your Azure resources being listed doesn't have a resource group which is something that we (wrongly) assumed every Azure resource had.

Could you see if this workaround resolves your issue?

  1. Click "Group By" on the Resources ribbon
  2. Try grouping by Resource Type image
JLZ1783 commented 10 months ago

I don't believe resources groups don't exist because they definitely do. But also, I reverted to an older version and it worked as expected and shows all the RGs in the subscription.

Changing group by does seem to work on the v0.8.0.