microsoft / vscode-azure-account

Common Azure Login extension for VS Code
https://marketplace.visualstudio.com/items?itemName=ms-vscode.azure-account
Other
138 stars 129 forks source link

Element with id /subscriptions/(GUID) is already registered #160

Open pejuborg opened 4 years ago

pejuborg commented 4 years ago

Hi,

I'm using the extension Azure Functions which uses this extension to connect to Azure.

I can login, but I get a message saying "Element with id /subscriptions/GUID) is already registered"

Also, I don't see any of the functions I already have.

pejuborg commented 4 years ago

After further checking it seems to caused by the fact that I've logged in with different accounts that have access to the same subscription.

jlieuw commented 4 years ago

After further checking it seems to caused by the fact that I've logged in with different accounts that have access to the same subscription.

try signing out of azure in vs code: F1 + Seach: Azure Sign Out Then sign back in and see if it works

GeorgeWieggers commented 4 years ago

In case anyone is still struggling with this issue...

Try selecting your Azure subscriptions manually in VS Code: F1 + Search: Azure Select Subscriptions Then, select the appropiate subscription(s).

BUT.....: if subscriptions are listed twice in the drop down, then make sure to select each subscription only once.

sgiovinetti commented 3 years ago

thanks @GeorgeWieggers this worked for me.

Btw my issue is that I have a customer subscription onboarded on my tenant with Azure Lighthouse, somehow the azure account extension sees it duplicated.

wwlorey commented 3 years ago

Dedupe accounts

HariKrishnaChowdary commented 1 year ago

I couldn't resolve the issue with the above steps.. Can someone help me resolve the issue...

Wojciech-Rozanski-CDT commented 6 months ago

I am experiencing the same problem. I'm logging in with an account which is used with Azure Lighthouse. I make sure that only my personal subscription is selected, however after a refresh I get the same message:

Element with id /subscriptions/xxx is already registered

With xxx being one of my Client's subscriptions.

I can't see any of my own resources. Logging out and logging back in does not help.