Azure / Azure/azure-cli

az login fails

Open
#32,371 8 comments 0 reactions 2 assignees Claimed by @ReaNAiveD View on GitHub
Account act-identity-squad ARM Auto-Assign bug MSAL Possible-Solution Service Attention Similar-Issue
Dominant language
Python
Stars
4.6k
Forks
3.5k
Avg merge
3d 2h
Merged PRs (30d)
60

Description

### Describe the bug

I am attempting to use the az cli command "az login" to login to Azure from my corp-managed device and get the error added below.

This is on a corp managed device, which has full access to all internal services, shows as connected on the CompanyPortal etc.

I have updated to the latest cli and cleared the account info (via az account clear) and set the core.enable_broker_on_windows = true

with no change in behavior.

### Related command

no related commands - just az login

### Errors

az login
Select the account you want to log in with. For more information on login with Azure CLI, see https://go.microsoft.com/fwlink/?linkid=2271136

Retrieving tenants and subscriptions for the selection...
The command failed with an unexpected error. Here is the traceback:
argument of type 'NoneType' is not iterable

### Issue script & Debug output

NA

### Expected behavior

I can loginto Azure and view resources, subscriptions etc

### Environment Summary

azure-cli 2.78.0

core 2.78.0
telemetry 1.1.0

Dependencies:
msal 1.34.0b1
azure-mgmt-resource 23.3.0

Python location 'C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\python.exe'
Config directory 'C:\Users\ADMIN_chrisseg\.azure'
Extensions directory 'C:\Users\ADMIN_chrisseg\.azure\cliextensions'

Python (Windows) 3.13.7 (tags/v3.13.7:bcee1c3, Aug 14 2025, 14:06:58) [MSC v.1944 32 bit (Intel)]

Legal docs and information: aka.ms/AzureCliLegal


Your CLI is up-to-date.

### Additional context

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.