Leask / halbot

Just another `ChatGPT` / `Gemini` / `Mistral (by ollama)` Telegram bob, which is simple design, easy to use, extendable and fun.
https://leaskh.com/post/711636926789271552/halbot
MIT License
101 stars 16 forks source link

error_code: 400, description: 'Bad Request: replied message not found' #20

Closed Am1nCmd closed 1 year ago

Am1nCmd commented 1 year ago

`[BOT 2023-04-12T06:10:01.131Z] INFO: No suitable response. /root/node_modules/telegraf/lib/core/network/client.js:293 throw new error_1.default(data, { method, payload }); ^

TelegramError: 400: Bad Request: replied message not found at Telegram.callApi (/root/node_modules/telegraf/lib/core/network/client.js:293:19) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async ctx.ok (file:///root/node_modules/utilitas/lib/bot.mjs:150:31) at async ok (file:///root/node_modules/halbot/skills/chat.mjs:38:16) at async action (file:///root/node_modules/halbot/skills/chat.mjs:40:5) at async execute (/root/node_modules/telegraf/lib/composer.js:485:17) at async /root/node_modules/telegraf/lib/composer.js:486:21 at async execute (/root/node_modules/telegraf/lib/composer.js:485:17) at async /root/node_modules/telegraf/lib/composer.js:486:21 at async action (file:///root/node_modules/halbot/skills/prepare.mjs:33:5) { response: { ok: false, error_code: 400, description: 'Bad Request: replied message not found' }, on: { method: 'sendMessage', payload: { chat_id: -1001300986220, reply_to_message_id: 15938, disable_notification: false, md: true, onProgress: true, text: '🚀 You:\n\n/stats@AmGPT_bot\n\n🤖 Bing (Sydney):\n\n💬' } } }

Node.js v19.8.1`

not sure what's wrong.

I just run the bot with npx halbot and it giving an error

Leask commented 1 year ago

How can I reproduce this issue?

Leask commented 1 year ago

Which version are you on?

Am1nCmd commented 1 year ago

Which version are you on?

🤖 halbot v1990.1.51

Leask commented 1 year ago

Can you upgrade to the latest version? Thanks!

Leask commented 1 year ago

If you can still reproduce this issue in the latest version, post your logs again.

Am1nCmd commented 1 year ago

If you can still reproduce this issue in the latest version, post your logs again.

sure, I'll update it first

Leask commented 1 year ago

I am updating the paging feature. I am not sure if the update is raising new issues. 🤣

Leask commented 1 year ago

Any update? It's late here. I am going to sleep now. If you can reproduce the error log, I will fix it tomorrow. Thanks! Have a good one!

Am1nCmd commented 1 year ago

already updated it, but not sure about reproducing the issue.

I will post the logs again if got an error.

please go to sleep, take it easy bro

On 12 Apr 2023, at 14.18, Leask @.**@.>> wrote:

Any update? It's late here. I am going to sleep now. If you can reproduce the error log, I will fix it tomorrow. Thanks! Have a good one!

— Reply to this email directly, view it on GitHubhttps://github.com/Leask/halbot/issues/20#issuecomment-1504787451, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADVBANLI7S76G22C4EL2KNLXAZJN5ANCNFSM6AAAAAAW3HDIJE. You are receiving this because you authored the thread.Message ID: @.***>

Am1nCmd commented 1 year ago

got new error

`Unhandled error while processing { update_id: 187618935, message: { message_id: 2543, from: { id: 116360017, is_bot: false, first_name: '^Amin', last_name: 'Aenurahman', username: 'Am1nCmd', language_code: 'en', is_premium: true }, chat: { id: 116360017, first_name: '^Amin', last_name: 'Aenurahman', username: 'Am1nCmd', type: 'private' }, date: 1681305645, text: 'apa saja yang ada di jurnal paper "Mapping the NFT revolution:\n' + 'market trends, trade networks,\n' + 'and visual features" untuk bab IV dan Bab V' } } /root/node_modules/p-timeout/index.js:39 const timeoutError = fallback instanceof Error ? fallback : new TimeoutError(message); ^

TimeoutError: Promise timed out after 90000 milliseconds at Timeout._onTimeout (/root/node_modules/p-timeout/index.js:39:64) at listOnTimeout (node:internal/timers:573:17) at process.processTimers (node:internal/timers:514:7)

Node.js v19.8.1`

Am1nCmd commented 1 year ago
image

bot stop answering (latest version) tested on VPS Linux Ubuntu

Leask commented 1 year ago

Timeout is an issue on the Bing side. Bing can not finish the whole session in 9s. I will handle all these kinds of timeout issues in the next version, thanks!

Am1nCmd commented 1 year ago

ah noted that, thx for info

On 12 Apr 2023, at 21.43, Leask @.**@.>> wrote:

Timeout is an issue on the Bing side. Bing can not finish the whole session in 9s. I will handle all these kinds of timeout issues in the next version, thanks!

— Reply to this email directly, view it on GitHubhttps://github.com/Leask/halbot/issues/20#issuecomment-1505402950, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADVBANKJL6DS6LYJEST6V3TXA25QTANCNFSM6AAAAAAW3HDIJE. You are receiving this because you authored the thread.Message ID: @.***>

Am1nCmd commented 1 year ago

got new error using latest version

/root/node_modules/node-fetch/lib/index.js:1505 reject(new FetchError(request to ${request.url} failed, reason: ${err.message}, 'system', err)); ^ FetchError: request to https://api.telegram.org/bot6148778231:[REDACTED]/editMessageText failed, reason: getaddrinfo EAI_AGAIN api.telegram.org at ClientRequest. (/root/node_modules/node-fetch/lib/index.js:1505:11) at ClientRequest.emit (node:events:512:28) at TLSSocket.socketErrorListener (node:_http_client:495:9) at TLSSocket.emit (node:events:512:28) at emitErrorNT (node:internal/streams/destroy:151:8) at emitErrorCloseNT (node:internal/streams/destroy:116:3) at process.processTicksAndRejections (node:internal/process/task_queues:82:21) { type: 'system', errno: 'EAI_AGAIN', code: 'EAI_AGAIN' }

Node.js v19.8.1

Leask commented 1 year ago

‘getaddrinfo’ is a network issue. Your computer cannot connect to the telegram server at that time. Is this an occasion issue or a repeating issue?

On Thu, Apr 13, 2023 at 8:57 AM Am1nCmd @.***> wrote:

got new error using latest version

/root/node_modules/node-fetch/lib/index.js:1505 reject(new FetchError(request to ${request.url} failed, reason: ${err.message}`, 'system', err)); ^ FetchError: request to https://api.telegram.org/bot6148778231:[REDACTED]/editMessageText failed, reason: getaddrinfo EAI_AGAIN api.telegram.org at ClientRequest. (/root/node_modules/node-fetch/lib/index.js:1505:11) at ClientRequest.emit (node:events:512:28) at TLSSocket.socketErrorListener (node:_http_client:495:9) at TLSSocket.emit (node:events:512:28) at emitErrorNT (node:internal/streams/destroy:151:8) at emitErrorCloseNT (node:internal/streams/destroy:116:3) at process.processTicksAndRejections (node:internal/process/task_queues:82:21) { type: 'system', errno: 'EAI_AGAIN', code: 'EAI_AGAIN' }

Node.js v19.8.1`

— Reply to this email directly, view it on GitHub https://github.com/Leask/halbot/issues/20#issuecomment-1506920980, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABY4PTNEWAWGQZIAGB3BYDXA7Z4FANCNFSM6AAAAAAW3HDIJE . You are receiving this because you commented.Message ID: @.***>

--

Sincerely,

Sixia "Leask" Huang https://leaskh.com

Leask commented 1 year ago

Any issue related to network issues has already been watched in the latest version. Thanks for your reminder. The bot will not crash on network issues in most cases.

Leask commented 1 year ago

@Am1nCmd would you like to try the official Halbot instant for a month? I appreciate your support of the project. Thank you!🙏

Am1nCmd commented 1 year ago

Thank you for the offer, but no, I already running this bot on VPS. I just want appreciation for your work, hopefully it will be a motivation to continue developing this project. I like it, and I'm waiting for updates related to its new features.

Leask commented 1 year ago

Thanks a lot. I will keep updating this project. :)