louking / contracts

1 stars 2 forks source link

race calendar view: HTTPConnection object at 0x0000024ECA2CBF10>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed #475

Closed louking closed 2 months ago

louking commented 3 months ago

Verified using sandbox that this is just in development environment. Is it a function of the new laptop?

127.0.0.1 - - [28/Jul/2024 06:10:04] "GET /admin/calendar HTTP/1.1" 500 -
Error on request:
Traceback (most recent call last):
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\connection.py", line 174, in _new_conn
    conn = connection.create_connection(
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\util\connection.py", line 72, in create_connection
    for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM):
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\socket.py", line 954, 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\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\connectionpool.py", line 715, in urlopen
    httplib_response = self._make_request(
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\connectionpool.py", line 416, in _make_request
    conn.request(method, url, **httplib_request_kw)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\connection.py", line 244, in request
    super(HTTPConnection, self).request(method, url, body=body, headers=headers)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\http\client.py", line 1285, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\http\client.py", line 1331, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\http\client.py", line 1280, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\http\client.py", line 1040, in _send_output
    self.send(msg)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3568.0_x64__qbz5n2kfra8p0\lib\http\client.py", line 980, in send
    self.connect()
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\connection.py", line 205, in connect
    conn = self._new_conn()
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\connection.py", line 186, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPConnection object at 0x0000024ECA2CBF10>: 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:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\requests\adapters.py", line 486, in send
    resp = conn.urlopen(
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\connectionpool.py", line 799, in urlopen
    retries = retries.increment(
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\urllib3\util\retry.py", line 592, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='dev.localhost', port=5000): Max retries exceeded with url: /admin/events/saform (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x0000024ECA2CBF10>: 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:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\werkzeug\serving.py", line 362, in run_wsgi
    execute(self.server.app)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\werkzeug\serving.py", line 323, in execute
    application_iter = app(environ, start_response)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\app.py", line 2213, in __call__
    return self.wsgi_app(environ, start_response)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\app.py", line 2193, in wsgi_app
    response = self.handle_exception(e)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\app.py", line 2190, in wsgi_app
    response = self.full_dispatch_request()
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\app.py", line 1486, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\app.py", line 1484, in full_dispatch_request
    rv = self.dispatch_request()
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\app.py", line 1469, in dispatch_request
    return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask_security\decorators.py", line 525, in decorated_view
    return fn(*args, **kwargs)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\views.py", line 109, in view
    return current_app.ensure_sync(self.dispatch_request)(**kwargs)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\flask\views.py", line 190, in dispatch_request
    return current_app.ensure_sync(meth)(**kwargs)
  File "C:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\contracts\views\admin\admin_eventscalendar.py", line 232, in get
    dt = requests.get('{}{}/saform'.format( request.url_root[:-1], url_for( '.events-superadmin' )))
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\requests\api.py", line 73, in get
    return request("get", url, params=params, **kwargs)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\requests\api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\requests\sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\requests\sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
  File "c:\Users\lking\Documents\Lou's Software\projects\contracts\contracts\venv\lib\site-packages\requests\adapters.py", line 519, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPConnectionPool(host='dev.localhost', port=5000): Max retries exceeded with url: /admin/events/saform (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x0000024ECA2CBF10>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))
127.0.0.1 - - [28/Jul/2024 06:10:37] "GET /admin/events/saform HTTP/1.1" 200 -
louking commented 2 months ago

Had to update C:\Windows\System32\drivers\etc\hosts

127.0.0.1 dev.localhost