jaller94 / matrix-plays-pokemon

Control the mgba emulator via Matrix chat

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Matrix bot not reading messages

Sleuth56 opened this issue · comments

Any ideas what is causing these errors?

> matrix-plays-pokemon@0.0.0 start
> ts-node src/index.ts

TCP connection established with the server.
Sat, 12 Nov 2022 19:17:42 GMT [ERROR] [MatrixHttpClient] (REQ-6) { errcode: 'M_NOT_FOUND', error: 'Event not found.' }
Sat, 12 Nov 2022 19:17:42 GMT [ERROR] [MatrixClientLite] Error handling sync Error: invalid type: map, expected a sequence at line 1 column 0

Is this preventing the bot from working or are they just some "ERROR" warnings from matrix-bot-sdk?

It is preventing the bot from working.

I decided to change the logger to debug and run it from scratch. New matrix account fresh npm install no storage folder. I still cannot understand what's wrong but maybe it helps you.
The line in the sdk that prints [ERROR] [MatrixClientLite] Error handling sync Error: invalid type: map, expected a sequence at line 1 column 0 is https://github.com/turt2live/matrix-bot-sdk/blob/main/src/MatrixClient.ts#L724

Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixClientLite] End-to-end encryption client created
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-1) GET https://matrix.rexrobotics.org/_matrix/client/v3/account/whoami
TCP connection established with the server.
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-2) GET https://matrix.rexrobotics.org/_matrix/client/v3/user/%40matrix-plays-pokemon%3Arexrobotics.org/account_data/m.direct
Tue, 15 Nov 2022 03:42:51 GMT [ERROR] [MatrixHttpClient] (REQ-2) { errcode: 'M_NOT_FOUND', error: 'Account data not found' }
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-3) POST https://matrix.rexrobotics.org/_matrix/client/v3/keys/query
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-4) POST https://matrix.rexrobotics.org/_matrix/client/v3/createRoom
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-5) PUT https://matrix.rexrobotics.org/_matrix/client/v3/user/%40matrix-plays-pokemon%3Arexrobotics.org/account_data/m.direct
Tue, 15 Nov 2022 03:42:51 GMT [INFO] [index] Starting bot...
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-6) GET https://matrix.rexrobotics.org/_matrix/client/v3/user/%40matrix-plays-pokemon%3Arexrobotics.org/account_data/m.direct
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixClientLite] No filter given or invalid object - using defaults.
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixClientLite] Populating joined rooms to avoid excessive join emits
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-7) GET https://matrix.rexrobotics.org/_matrix/client/v3/joined_rooms
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixClientLite] Preparing end-to-end encryption
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-8) GET https://matrix.rexrobotics.org/_matrix/client/v3/rooms/!DWXUfkYJXCmrBZDQdW%3Arexrobotics.org/state/m.room.encryption/
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-9) GET https://matrix.rexrobotics.org/_matrix/client/v3/rooms/!DWXUfkYJXCmrBZDQdW%3Arexrobotics.org/state/m.room.history_visibility/
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-10) GET https://matrix.rexrobotics.org/_matrix/client/v3/account/whoami
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [CryptoClient] Starting with device ID: SMYXGFBLPZ
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-11) POST https://matrix.rexrobotics.org/_matrix/client/v3/keys/upload
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-12) POST https://matrix.rexrobotics.org/_matrix/client/v3/keys/query
Tue, 15 Nov 2022 03:42:51 GMT [INFO] [MatrixClientLite] End-to-end encryption enabled
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixClientLite] Starting sync with filter ID 0
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixClientLite] Performing sync with token null
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixHttpClient] (REQ-13) GET https://matrix.rexrobotics.org/_matrix/client/v3/sync
Tue, 15 Nov 2022 03:42:51 GMT [DEBUG] [MatrixClientLite] Received sync. Next token: s1088708_3800535_2074_1530887_32541_214_18018_3081204_0
Tue, 15 Nov 2022 03:42:51 GMT [ERROR] [MatrixClientLite] Error handling sync Error: invalid type: map, expected a sequence at line 1 column 0
Tue, 15 Nov 2022 03:42:51 GMT [INFO] [MatrixClientLite] Backing off for 5825.937056236863ms
Tue, 15 Nov 2022 03:42:57 GMT [DEBUG] [MatrixClientLite] Performing sync with token s1088708_3800535_2074_1530887_32541_214_18018_3081204_0
Tue, 15 Nov 2022 03:42:57 GMT [DEBUG] [MatrixHttpClient] (REQ-14) GET https://matrix.rexrobotics.org/_matrix/client/v3/sync
Tue, 15 Nov 2022 03:42:57 GMT [DEBUG] [MatrixClientLite] Received sync. Next token: s1088710_3800535_2074_1530889_32545_214_18018_3081204_0
Tue, 15 Nov 2022 03:42:57 GMT [ERROR] [MatrixClientLite] Error handling sync Error: invalid type: map, expected a sequence at line 1 column 0
Tue, 15 Nov 2022 03:42:57 GMT [INFO] [MatrixClientLite] Backing off for 13198.222162813257ms