Feedbot errors on new posts (possibly following fedora upgrade) #1

Closed
opened 2023-05-18 15:02:35 +00:00 by spacenerdmo · 1 comment
Owner

The following stack trace was captured from the cron output

ERROR:root:bad stuff
Traceback (most recent call last):
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 7077, in get
    return clone.execute(database)[0]
           ~~~~~~~~~~~~~~~~~~~~~~~^^^
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 4441, in __getitem__
    return self.row_cache[item]
           ~~~~~~~~~~~~~~^^^^^^
IndexError: list index out of range

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/feedbot.py", line 103, in fetch
    entry = zdb.Entries.get(feedid=fid, link=link)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 6629, in get
    return sq.get()
           ^^^^^^^^
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 7080, in get
    raise self.model.DoesNotExist('%s instance matching query does '
models.EntriesDoesNotExist: <Model: Entries> instance matching query does not exist:
SQL: SELECT "t1"."id", "t1"."feedid", "t1"."link" FROM "entries" AS "t1" WHERE (("t1"."feedid" = ?) AND ("t1"."link" = ?)) LIMIT ? OFFSET ?
Params: [1, 'https://fosstodon.org/@thrrgilag/110390196905748368', 1, 0]

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/urllib3/connection.py", line 174, in _new_conn
    conn = connection.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/urllib3/util/connection.py", line 72, in create_connection
    for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM):
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/socket.py", line 962, in getaddrinfo
    for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socket.gaierror: [Errno -2] Name or service not known

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 703, in urlopen
    httplib_response = self._make_request(
                       ^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 386, in _make_request
    self._validate_conn(conn)
  File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 1042, in _validate_conn
    conn.connect()
  File "/usr/lib/python3.11/site-packages/urllib3/connection.py", line 358, in connect
    self.sock = conn = self._new_conn()
                       ^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/urllib3/connection.py", line 186, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x7f6f9b5eb6d0>: Failed to establish a new connection: [Errno -2] Name or service not known

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/requests/adapters.py", line 489, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 787, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/urllib3/util/retry.py", line 592, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='api.pnut.io', port=443): Max retries exceeded with url: /v0/posts (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f6f9b5eb6d0>: Failed to establish a new connection: [Errno -2] Name or service not known'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/feedbot.py", line 166, in pnutpost
    p, meta = pnutpy.api.create_post(data={'text': text, 'raw': raw})
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/pnutpy/api.py", line 137, in run
    resp = resp_method(method, proccessed_path, params=parameters, raw_response=raw_response, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/pnutpy/api.py", line 98, in request_json
    return self.request(method, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/thrrgilag/.local/lib/python3.11/site-packages/pnutpy/api.py", line 54, in request
    response = super(API, self).request(method, url, *args, **kwargs)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/requests/sessions.py", line 587, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/requests/sessions.py", line 701, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/requests/adapters.py", line 565, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='api.pnut.io', port=443): Max retries exceeded with url: /v0/posts (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f6f9b5eb6d0>: Failed to establish a new connection: [Errno -2] Name or service not known'))
The following stack trace was captured from the cron output ``` ERROR:root:bad stuff Traceback (most recent call last): File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 7077, in get return clone.execute(database)[0] ~~~~~~~~~~~~~~~~~~~~~~~^^^ File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 4441, in __getitem__ return self.row_cache[item] ~~~~~~~~~~~~~~^^^^^^ IndexError: list index out of range During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/thrrgilag/.local/lib/python3.11/site-packages/feedbot.py", line 103, in fetch entry = zdb.Entries.get(feedid=fid, link=link) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 6629, in get return sq.get() ^^^^^^^^ File "/home/thrrgilag/.local/lib/python3.11/site-packages/peewee.py", line 7080, in get raise self.model.DoesNotExist('%s instance matching query does ' models.EntriesDoesNotExist: <Model: Entries> instance matching query does not exist: SQL: SELECT "t1"."id", "t1"."feedid", "t1"."link" FROM "entries" AS "t1" WHERE (("t1"."feedid" = ?) AND ("t1"."link" = ?)) LIMIT ? OFFSET ? Params: [1, 'https://fosstodon.org/@thrrgilag/110390196905748368', 1, 0] During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/urllib3/connection.py", line 174, in _new_conn conn = connection.create_connection( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/urllib3/util/connection.py", line 72, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/socket.py", line 962, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ socket.gaierror: [Errno -2] Name or service not known During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 703, in urlopen httplib_response = self._make_request( ^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 386, in _make_request self._validate_conn(conn) File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 1042, in _validate_conn conn.connect() File "/usr/lib/python3.11/site-packages/urllib3/connection.py", line 358, in connect self.sock = conn = self._new_conn() ^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/urllib3/connection.py", line 186, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x7f6f9b5eb6d0>: Failed to establish a new connection: [Errno -2] Name or service not known During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/requests/adapters.py", line 489, in send resp = conn.urlopen( ^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/urllib3/connectionpool.py", line 787, in urlopen retries = retries.increment( ^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/urllib3/util/retry.py", line 592, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='api.pnut.io', port=443): Max retries exceeded with url: /v0/posts (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f6f9b5eb6d0>: Failed to establish a new connection: [Errno -2] Name or service not known')) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/thrrgilag/.local/lib/python3.11/site-packages/feedbot.py", line 166, in pnutpost p, meta = pnutpy.api.create_post(data={'text': text, 'raw': raw}) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/thrrgilag/.local/lib/python3.11/site-packages/pnutpy/api.py", line 137, in run resp = resp_method(method, proccessed_path, params=parameters, raw_response=raw_response, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/thrrgilag/.local/lib/python3.11/site-packages/pnutpy/api.py", line 98, in request_json return self.request(method, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/thrrgilag/.local/lib/python3.11/site-packages/pnutpy/api.py", line 54, in request response = super(API, self).request(method, url, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/requests/sessions.py", line 587, in request resp = self.send(prep, **send_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/requests/sessions.py", line 701, in send r = adapter.send(request, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/requests/adapters.py", line 565, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='api.pnut.io', port=443): Max retries exceeded with url: /v0/posts (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f6f9b5eb6d0>: Failed to establish a new connection: [Errno -2] Name or service not known')) ```
spacenerdmo self-assigned this 2023-05-18 15:02:35 +00:00
spacenerdmo added the
bug
label 2023-05-18 15:02:52 +00:00
spacenerdmo added
wontfix
and removed
bug
labels 2023-09-10 15:38:32 +00:00
Author
Owner

Latest testing on a different Fedora 38 machine does not yield these errors. Furthermore I've moved my activity pub profile from Fosstodon (Mastodon instance) to a new personal Friendica instance and this code needs to be adapted.

Latest testing on a different Fedora 38 machine does not yield these errors. Furthermore I've moved my activity pub profile from Fosstodon (Mastodon instance) to a new personal Friendica instance and this code needs to be adapted.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: spacenerdmo/feedbot#1
No description provided.