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

Name resolution errors in StackExchange watcher #968

Open
benoit74 opened this issue May 14, 2024 · 0 comments
Open

Name resolution errors in StackExchange watcher #968

benoit74 opened this issue May 14, 2024 · 0 comments
Labels

Comments

@benoit74
Copy link
Collaborator

benoit74 commented May 14, 2024

We are experiencing some name resolution errors on Zimfarm watcher, while when resolving the name from the container shell (with ping, not much other utility available) it works well.

 [2024-05-14 12:11:12,592::ERROR] FAILED. An error occurred: HTTPSConnectionPool(host='archive.org', port=443): Max retries exceeded with url: /download/stackexchange//drupal.stackexchange.com.7z (Caused by NameResolutionError("<urllib3.connection.HTTPSConnection objec │
│ [2024-05-14 12:11:12,593::ERROR] HTTPSConnectionPool(host='archive.org', port=443): Max retries exceeded with url: /download/stackexchange//drupal.stackexchange.com.7z (Caused by NameResolutionError("<urllib3.connection.HTTPSConnection object at 0x7f95583fb1d0>: Faile │
│ Traceback (most recent call last):                                                                                                                                                                                                                                           │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connection.py", line 198, in _new_conn                                                                                                                                                                               │
│     sock = connection.create_connection(                                                                                                                                                                                                                                     │
│            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                                     │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/util/connection.py", line 60, in create_connection                                                                                                                                                                   │
│     for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM):                                                                                                                                                                                                   │
│                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                    │
│   File "/usr/local/lib/python3.12/socket.py", line 963, in getaddrinfo                                                                                                                                                                                                       │
│     for res in _socket.getaddrinfo(host, port, family, type, proto, flags):                                                                                                                                                                                                  │
│                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                   │
│ socket.gaierror: [Errno -3] Try again                                                                                                                                                                                                                                        │
│                                                                                                                                                                                                                                                                              │
│ The above exception was the direct cause of the following exception:                                                                                                                                                                                                         │
│                                                                                                                                                                                                                                                                              │
│ Traceback (most recent call last):                                                                                                                                                                                                                                           │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connectionpool.py", line 793, in urlopen                                                                                                                                                                             │
│     response = self._make_request(                                                                                                                                                                                                                                           │
│                ^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                                           │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connectionpool.py", line 491, in _make_request                                                                                                                                                                       │
│     raise new_e                                                                                                                                                                                                                                                              │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connectionpool.py", line 467, in _make_request                                                                                                                                                                       │
│     self._validate_conn(conn)                                                                                                                                                                                                                                                │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connectionpool.py", line 1099, in _validate_conn                                                                                                                                                                     │
│     conn.connect()                                                                                                                                                                                                                                                           │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connection.py", line 616, in connect                                                                                                                                                                                 │
│     self.sock = sock = self._new_conn()                                                                                                                                                                                                                                      │
│                        ^^^^^^^^^^^^^^^^                                                                                                                                                                                                                                      │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connection.py", line 205, in _new_conn                                                                                                                                                                               │
│     raise NameResolutionError(self.host, self, e) from e                                                                                                                                                                                                                     │
│ urllib3.exceptions.NameResolutionError: <urllib3.connection.HTTPSConnection object at 0x7f95583fb1d0>: Failed to resolve 'archive.org' ([Errno -3] Try again)                                                                                                                │
│                                                                                                                                                                                                                                                                              │
│ The above exception was the direct cause of the following exception:                                                                                                                                                                                                         │
│ Traceback (most recent call last):                                                                                                                                                                                                                                           │
│   File "/usr/local/lib/python3.12/site-packages/requests/adapters.py", line 486, in send                                                                                                                                                                                     │
│     resp = conn.urlopen(                                                                                                                                                                                                                                                     │
│            ^^^^^^^^^^^^^                                                                                                                                                                                                                                                     │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/connectionpool.py", line 847, in urlopen                                                                                                                                                                             │
│     retries = retries.increment(                                                                                                                                                                                                                                             │
│               ^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                                             │
│   File "/usr/local/lib/python3.12/site-packages/urllib3/util/retry.py", line 515, in increment                                                                                                                                                                               │
│     raise MaxRetryError(_pool, url, reason) from reason  # type: ignore[arg-type]                                                                                                                                                                                            │
│     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                      │
│ urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='archive.org', port=443): Max retries exceeded with url: /download/stackexchange//drupal.stackexchange.com.7z (Caused by NameResolutionError("<urllib3.connection.HTTPSConnection object at 0x7f95583fb1d0>: Fail │
│                                                                                                                                                                                                                                                                              │
│ During handling of the above exception, another exception occurred:                                                                                                                                                                                                          │
│                                                                                                                                                                                                                                                                              │
│ Traceback (most recent call last):                                                                                                                                                                                                                                           │
│   File "/usr/local/bin/watcher", line 583, in entrypoint                                                                                                                                                                                                                     │
│     sys.exit(runner.run())                                                                                                                                                                                                                                                   │
│              ^^^^^^^^^^^^                                                                                                                                                                                                                                                    │
│   File "/usr/local/bin/watcher", line 490, in run                                                                                                                                                                                                                            │
│     self.check_and_go()                                                                                                                                                                                                                                                      │
│   File "/usr/local/bin/watcher", line 427, in check_and_go                                                                                                                                                                                                                   │
│     last_modified = get_last_modified_for(url)                                                                                                                                                                                                                               │
│                     ^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                               │
│   File "/usr/local/bin/watcher", line 68, in get_last_modified_for                                                                                                                                                                                                           │
│     with requests.head(url, allow_redirects=True) as resp:                                                                                                                                                                                                                   │
│          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                            │
│   File "/usr/local/lib/python3.12/site-packages/requests/api.py", line 100, in head                                                                                                                                                                                          │
│     return request("head", url, **kwargs)                                                                                                                                                                                                                                    │
│            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                                    │
│   File "/usr/local/lib/python3.12/site-packages/requests/api.py", line 59, in request                                                                                                                                                                                        │
│     return session.request(method=method, url=url, **kwargs)                                                                                                                                                                                                                 │
│            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                 │
│   File "/usr/local/lib/python3.12/site-packages/requests/sessions.py", line 589, in request                                                                                                                                                                                  │
│     resp = self.send(prep, **send_kwargs)                                                                                                                                                                                                                                    │
│            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                                    │
│   File "/usr/local/lib/python3.12/site-packages/requests/sessions.py", line 703, in send                                                                                                                                                                                     │
│     r = adapter.send(request, **kwargs)                                                                                                                                                                                                                                      │
│         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                                                                                                                                                                                                                                      │
│   File "/usr/local/lib/python3.12/site-packages/requests/adapters.py", line 519, in send                                                                                                                                                                                     │
│     raise ConnectionError(e, request=request)                                                                                                                                                                                                                                │
│ requests.exceptions.ConnectionError: HTTPSConnectionPool(host='archive.org', port=443): Max retries exceeded with url: /download/stackexchange//drupal.stackexchange.com.7z (Caused by NameResolutionError("<urllib3.connection.HTTPSConnection object at 0x7f95583fb1d0>: F │
│

Restarting the container helped a bit but not much

@benoit74 benoit74 added the bug label May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant