Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Errno 11001] getaddrinfo failed when running pipupgrade #121

Open
st1led opened this issue Sep 30, 2021 · 1 comment
Open

[Errno 11001] getaddrinfo failed when running pipupgrade #121

st1led opened this issue Sep 30, 2021 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@st1led
Copy link

st1led commented Sep 30, 2021

What's the bug all about?

I get a cascade of exceptions when trying to run pipupgrade. Could this be due to the fact that in pip I'm using a custom index-url? I didn't find a place to set it up in pipupgrade in case I have to.

What command led to this issue?

Please type the exact command that led to this issue.

pipupgrade

Logs

Please paste the logs using pipupgrade --verbose

(Python-Default) C:\Users\st1led>pipupgrade --verbose
2021-09-30 10:47:43,326 | INFO | Environment: {'version': '0.2.0', 'python_version': '3.9.5', 'os': 'Windows-10-10.0.18363-SP0', 'config
': {'path': {'BASE': 'c:\\users\\st1led\\environments\\python-default\\lib\\site-packages\\bpyutils', 'DATA': 'c:\\users\\st1led\\envi
ronments\\python-default\\lib\\site-packages\\bpyutils\\data', 'CACHE': 'C:\\Users\\st1led\\.config\\bpyutils', 'JOBS': 'c:\\users\\ac3
2967\\environments\\python-default\\lib\\site-packages\\bpyutils\\jobs'}}, 'settings': {'settings': {'version': '0.2.0', 'cache_timeout'
: '86400', 'jobs': '12'}}}
2021-09-30 10:47:43,326 | INFO | Arguments Passed: {'args': (), 'kwargs': {'ARGUMENTS': <class 'inspect._empty'>, 'packages': [], 'resol
ve': False, 'ignore': None, 'pip_path': None, 'yes': 0, 'clean': 0, 'check': 0, 'upgrade_type': ['minor', 'patch'], 'latest': 0, 'format
': 'table', 'all': 0, 'pip': 0, 'self': False, 'requirements': None, 'pipfile': None, 'interactive': 0, 'project': None, 'git_username':
 None, 'git_email': None, 'pull_request': False, 'github_access_token': None, 'github_reponame': None, 'github_username': None, 'target_
branch': 'master', 'jobs': 12, 'user': 0, 'no_included_requirements': 0, 'no_cache': 0, 'output': None, 'ignore_error': 0, 'force': 0, '
doctor': False, 'no_color': 0, 'verbose': True}, 'a': <pipupgrade.commands.to_params.<locals>.O object at 0x000001755CADCDF0>}
Checking...
2021-09-30 10:47:43,326 | INFO | `pip` executables found: ['C:\\Users\\st1led\\Environments\\Python-Default\\Scripts\\pip.EXE', 'C:\\Us
ers\\st1led\\Environments\\Python-Default\\Scripts\\pip3.EXE']
2021-09-30 10:47:43,326 | INFO | Using 12 jobs...
2021-09-30 10:47:44,143 | INFO | Fetching installed packages for C:\Users\st1led\Environments\Python-Default\Scripts\pip3.EXE...
2021-09-30 10:47:44,143 | INFO | Executing command: C:\Users\st1led\Environments\Python-Default\Scripts\pip3.EXE list --outdated --form
at json
2021-09-30 10:47:44,159 | INFO | Fetching installed packages for C:\Users\st1led\Environments\Python-Default\Scripts\pip.EXE...
2021-09-30 10:47:44,159 | INFO | Executing command: C:\Users\st1led\Environments\Python-Default\Scripts\pip.EXE list --outdated --forma
t json
2021-09-30 10:47:50,123 | INFO | 3 packages found for C:\Users\st1led\Environments\Python-Default\Scripts\pip3.EXE.
2021-09-30 10:47:50,222 | INFO | 3 packages found for C:\Users\st1led\Environments\Python-Default\Scripts\pip.EXE.
2021-09-30 10:47:51,224 | INFO | Initializing Package {'name': 'setuptools', 'version': '56.0.0', 'latest_version': '58.1.0', 'latest_fi
letype': 'wheel'} of type <class 'dict'>...
2021-09-30 10:47:51,224 | INFO | Fetching package setuptools information from DB...
2021-09-30 10:47:51,224 | INFO | Fetching PyPI info for package <Package setuptools (56.0.0)>...
2021-09-30 10:47:51,224 | INFO | Dispatching GET request with arguments ('https://pypi.org/pypi/setuptools/json',) and parameters {}.
2021-09-30 10:47:51,302 | INFO | Initializing Package {'name': 'click', 'version': '7.1.2', 'latest_version': '8.0.1', 'latest_filetype'
: 'wheel'} of type <class 'dict'>...
2021-09-30 10:47:51,302 | INFO | Fetching package click information from DB...
2021-09-30 10:47:51,318 | INFO | Fetching PyPI info for package <Package click (7.1.2)>...
2021-09-30 10:47:51,318 | INFO | Dispatching GET request with arguments ('https://pypi.org/pypi/click/json',) and parameters {}.
2021-09-30 10:47:51,356 | INFO | Initializing Package {'name': 'jupyter-client', 'version': '7.0.4', 'latest_version': '7.0.5', 'latest_
filetype': 'wheel'} of type <class 'dict'>...
2021-09-30 10:47:51,356 | INFO | Fetching package jupyter-client information from DB...
2021-09-30 10:47:51,356 | INFO | Fetching PyPI info for package <Package jupyter-client (7.0.4)>...
2021-09-30 10:47:51,356 | INFO | Dispatching GET request with arguments ('https://pypi.org/pypi/jupyter-client/json',) and parameters {}
.
2021-09-30 10:47:51,356 | INFO | Initializing Package {'name': 'click', 'version': '7.1.2', 'latest_version': '8.0.1', 'latest_filetype'
: 'wheel'} of type <class 'dict'>...
2021-09-30 10:47:51,356 | INFO | Fetching package click information from DB...
2021-09-30 10:47:51,356 | INFO | Fetching PyPI info for package <Package click (7.1.2)>...
2021-09-30 10:47:51,356 | INFO | Dispatching GET request with arguments ('https://pypi.org/pypi/click/json',) and parameters {}.

concurrent.futures.process._RemoteTraceback:
"""
concurrent.futures.process._RemoteTraceback:
"""
Traceback (most recent call last):
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\connection.py", line 174, in _new_conn
    conn = connection.create_connection(
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\util\connection.py", line 73, in create_connection
    for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM):
  File "C:\devtools\Python3\lib\socket.py", line 953, in getaddrinfo
    for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
socket.gaierror: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\connectionpool.py", line 699, in urlopen
    httplib_response = self._make_request(
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\connectionpool.py", line 382, in _make_request
    self._validate_conn(conn)
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\connectionpool.py", line 1010, in _validate_conn
    conn.connect()
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\connection.py", line 358, in connect
    conn = self._new_conn()
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\connection.py", line 186, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x000001B7CA2B2AC0>: Failed to establish a new conn
ection: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "c:\users\st1led\environments\python-default\lib\site-packages\requests\adapters.py", line 439, in send
    resp = conn.urlopen(
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen
    retries = retries.increment(
  File "c:\users\st1led\environments\python-default\lib\site-packages\urllib3\util\retry.py", line 574, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /pypi/click/json (Cause
d by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001B7CA2B2AC0>: Failed to establish a new connection: [Errno
 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 243, in _process_worker
    r = call_item.fn(*call_item.args, **call_item.kwargs)
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 202, in _process_chunk
    return [fn(*args) for args in chunk]
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 202, in <listcomp>
    return [fn(*args) for args in chunk]
  File "c:\users\st1led\environments\python-default\lib\site-packages\pipupgrade\model\package.py", line 138, in __init__
    _pypi_info = _get_pypi_info(self.name, raise_err = False) or { }
  File "c:\users\st1led\environments\python-default\lib\site-packages\pipupgrade\model\package.py", line 29, in _get_pypi_info
    res  = req.get(url)
  File "c:\users\st1led\environments\python-default\lib\site-packages\bpyutils\request\__init__.py", line 29, in get
    return req.get(*args, **kwargs) # pragma: no cover
  File "c:\users\st1led\environments\python-default\lib\site-packages\requests\api.py", line 75, in get
    return request('get', url, params=params, **kwargs)
  File "c:\users\st1led\environments\python-default\lib\site-packages\requests\api.py", line 61, in request
    return session.request(method=method, url=url, **kwargs)
  File "c:\users\st1led\environments\python-default\lib\site-packages\requests\sessions.py", line 542, in request
    resp = self.send(prep, **send_kwargs)
  File "c:\users\st1led\environments\python-default\lib\site-packages\requests\sessions.py", line 655, in send
    r = adapter.send(request, **kwargs)
  File "c:\users\st1led\environments\python-default\lib\site-packages\requests\adapters.py", line 516, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /pypi/click/json (Ca
used by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001B7CA2B2AC0>: Failed to establish a new connection: [Er
rno 11001] getaddrinfo failed'))
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 243, in _process_worker
    r = call_item.fn(*call_item.args, **call_item.kwargs)
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 202, in _process_chunk
    return [fn(*args) for args in chunk]
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 202, in <listcomp>
    return [fn(*args) for args in chunk]
  File "c:\users\st1led\environments\python-default\lib\site-packages\pipupgrade\commands\helper.py", line 331, in get_registry_from_pi
p
    registry     = Registry(source = pip_path, packages = packages,
  File "c:\users\st1led\environments\python-default\lib\site-packages\pipupgrade\model\registry.py", line 119, in __init__
    for package in pool.imap_unordered(partial(Package, **args), packages):
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 559, in _chain_from_iterable_of_lists
    for element in iterable:
  File "C:\devtools\Python3\lib\concurrent\futures\_base.py", line 608, in result_iterator
    yield fs.pop().result()
  File "C:\devtools\Python3\lib\concurrent\futures\_base.py", line 445, in result
    return self.__get_result()
  File "C:\devtools\Python3\lib\concurrent\futures\_base.py", line 390, in __get_result
    raise self._exception
requests.exceptions.ConnectionError: None: Max retries exceeded with url: /pypi/click/json (Caused by None)
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "c:\users\st1led\environments\python-default\lib\site-packages\pipupgrade\commands\__init__.py", line 79, in command
    return _command(**ARGUMENTS)
  File "c:\users\st1led\environments\python-default\lib\site-packages\pipupgrade\commands\__init__.py", line 240, in _command
    for registry in pool.imap_unordered(
  File "C:\devtools\Python3\lib\concurrent\futures\process.py", line 559, in _chain_from_iterable_of_lists
    for element in iterable:
  File "C:\devtools\Python3\lib\concurrent\futures\_base.py", line 608, in result_iterator
    yield fs.pop().result()
  File "C:\devtools\Python3\lib\concurrent\futures\_base.py", line 445, in result
    return self.__get_result()
  File "C:\devtools\Python3\lib\concurrent\futures\_base.py", line 390, in __get_result
    raise self._exception
requests.exceptions.ConnectionError: None: Max retries exceeded with url: /pypi/click/json (Caused by None)

An error occured while performing the above command. This could be an issue with
"pipupgrade". Kindly post an issue at https://github.com/achillesrasquinha/pipupgrade/issues
2021-09-30 10:47:51,471 | INFO | Initializing Package {'name': 'jupyter-client', 'version': '7.0.4', 'latest_version': '7.0.5', 'latest_
filetype': 'wheel'} of type <class 'dict'>...
2021-09-30 10:47:51,471 | INFO | Fetching package jupyter-client information from DB...
2021-09-30 10:47:51,471 | INFO | Fetching PyPI info for package <Package jupyter-client (7.0.4)>...
2021-09-30 10:47:51,471 | INFO | Dispatching GET request with arguments ('https://pypi.org/pypi/jupyter-client/json',) and parameters {}
.
2021-09-30 10:47:51,471 | INFO | Initializing Package {'name': 'setuptools', 'version': '56.0.0', 'latest_version': '58.1.0', 'latest_fi
letype': 'wheel'} of type <class 'dict'>...
2021-09-30 10:47:51,471 | INFO | Fetching package setuptools information from DB...
2021-09-30 10:47:51,471 | INFO | Fetching PyPI info for package <Package setuptools (56.0.0)>...
2021-09-30 10:47:51,471 | INFO | Dispatching GET request with arguments ('https://pypi.org/pypi/setuptools/json',) and parameters {}.
@st1led st1led added the bug Something isn't working label Sep 30, 2021
@achillesrasquinha
Copy link
Owner

Did you try again? Seems like a requests issue to me. Are you using a proxy by any chance?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants