Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/azure-cli-core/azure/cli/core/_profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -1202,6 +1202,11 @@ def _get_authorization_code_worker(authority_url, resource, results):
break
except socket.error as ex:
logger.warning("Port '%s' is taken with error '%s'. Trying with the next one", port, ex)
except UnicodeDecodeError:
Copy link
Member

Choose a reason for hiding this comment

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

except UnicodeDecodeError: [](start = 8, length = 26)

make sure we handle this exception in MSAL too

Copy link
Member Author

Choose a reason for hiding this comment

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

Sure.

logger.warning("Please make sure there is no international (Unicode) character in the computer name "
Copy link
Contributor

Choose a reason for hiding this comment

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

Just curious about that if we actually have international character in the compute name, the only way to get it passed is to rename the compute name ?

Copy link
Member Author

@jiasli jiasli Apr 16, 2020

Choose a reason for hiding this comment

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

The link does have instructions about how to bypass it: #12957

But using Unicode as a computer name is always a bad idea.

Copy link
Contributor

Choose a reason for hiding this comment

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

Got it.

r"or C:\Windows\System32\drivers\etc\hosts file's 127.0.0.1 entries. "
"For more details, please see https://github.com/Azure/azure-cli/issues/12957")
break

if reply_url is None:
logger.warning("Error: can't reserve a port for authentication reply url")
Expand Down