May 25, 2018

python tips


-> ModuleNotFoundError

ModuleNotFoundError: No module named 'openpyxl'

-> Cannot connect to proxy

pip3 install openpyxl

Collecting openpyxl
  Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x111744fd0>: Failed to establish a new connection: [Errno 8] nodename nor servname provided, or not known'))': /simple/openpyxl/



export https_proxy=https://<user>:<password>@proxy.company.com:8080

-> Could not install packages due to an EnvironmentError

Installing collected packages: jdcal, et-xmlfile, openpyxl

Could not install packages due to an EnvironmentError: [Errno 13] Permission denied: '/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/jdcal.py'
Consider using the `--user` option or check the permissions.


pip3 install --user openpyxl

-> pip for python 2x & pip3 for python 3x

No comments:

Post a Comment