ba0f3 / telebot.nim

Async Telegram Bot API Client implement in @Nim-Lang

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Doesn't work with nim devel

yglukhov opened this issue · comments

echo bot example from the readme doesn't work with nim devel (3bc625aff1664eb4206ae90d0a132c8f717e651d), because it seems procName is broken in async functions. Here's the log from the bot:

DEBUG, [11:05:40] Making request to https://api.telegram.org/bot<MY_TOKEN>/getMeIter_OOZOOZOnimbleZpkgsZtelebot4549O48O55Ztelebot_5418
DEBUG, [11:05:40] Unable to fetch my info 404 Not Found
Async traceback:
...

As seen from the log above the url ends with getMeIter_OOZOOZOnimbleZpkgsZtelebot4549O48O55Ztelebot_5418 instead of getMe.

does your token has special character? like \n?

P/S: I see the issue, I will check it soon

That surely got us somewhere, but unfortunately it still crashes if you try chatting with it.

Idk why but looks like something went wrong with httpclient, I will check it asap

Looks like httpclient is missing content-length header for multipart dataform.
Update: I found this on Nim issues nim-lang/Nim#14794