question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

CLI fails to import "requests" package

See original GitHub issue

Description

Outline the issue here: az login: ‘ValueError: need more than 2 values to unpack’


Environment summary

Install Method: How did you install the CLI? (e.g. pip, interactive script, apt-get, Docker, MSI, nightly)
Answer here: curl -L https://aka.ms/InstallAzureCli | bash

CLI Version: What version of the CLI and modules are installed? (Use az --version)
Answer here: 2.0.6

OS Version: What OS and version are you using?
Answer here: macOS Sierra 10.12.5

Shell Type: What shell are you using? (e.g. bash, cmd.exe, Bash on Windows)
Answer here: terminal/bash

EVW-MBA-2013:~ eric$ az login Traceback (most recent call last): File “/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py”, line 162, in _run_module_as_main “main”, fname, loader, pkg_name) File “/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py”, line 72, in _run_code exec code in run_globals File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/azure/cli/main.py”, line 23, in <module> exit_code = azure.cli.main.main(args) File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/azure/cli/main.py”, line 52, in main error_code = handle_exception(ex) File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/azure/cli/core/util.py”, line 34, in handle_exception from msrestazure.azure_exceptions import CloudError File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/msrestazure/init.py”, line 28, in <module> from .azure_configuration import AzureConfiguration File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/msrestazure/azure_configuration.py”, line 33, in <module> from msrest import Configuration File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/msrest/init.py”, line 27, in <module> from .configuration import Configuration File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/msrest/configuration.py”, line 36, in <module> import requests File “/Users/eric/lib/azure-cli/lib/python2.7/site-packages/requests/init.py”, line 49, in <module> major, minor, patch = urllib3.version.split(‘.’)[:3] ValueError: need more than 2 values to unpack

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
KylieLiangcommented, May 31, 2017

verified on FreeBSD 11. Works. Thank you.

0reactions
geekztercommented, May 31, 2017

Verified in macOS, thx.

Read more comments on GitHub >

github_iconTop Results From Across the Web

python - ImportError: No module named requests
Requests is not a built in module (does not come with the default python installation), so you will have to install it: OSX/Linux....
Read more >
[Fixed] ModuleNotFoundError: No module named 'requests'
Quick Fix: Python raises the ImportError: No module named 'requests' when it cannot find the library requests . The most frequent source of...
Read more >
How to PIP Install Requests Python Package - ActiveState
Allows you to send HTTP/1.1 PUT, DELETE, HEAD, GET and OPTIONS requests with ease. For example: import requests req = requests.request('GET', ' ...
Read more >
transfer fails with No module named 'requests' #9 - GitHub
it has installed no worries, added repos to the config, and then tried the transfer. it's between 2 az artifact feeds.
Read more >
How to import REQUESTS module in Python - CodeProject
I am using windows 7. Python 3.5.1.[64 bit]. If requests module is to be installed, then please direct me how? pip install requests...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found