Forum

Telegram.bot 18.0.0 silently crashes the program

Create of telegram bot client even grey without any clue

изображение

изображение

изображение

remove the netcore lib from the nuget package

in the meanwhile check this repo

@nissidis Thanks!
It should be noted that you must either restart VVVV after deleting or delete it first and then run it.

изображение

1 Like

ah maybe, it is just a workaround I found accidentally :D probably this shouldn’t be needful in anycase (to remove the netcore lib I mean)

It’s lucky that you discovered it at all
Hopefully the bug will be fixed later

In any case, Telegram.Bot.Extensions is parsed to nothing when you connect it to the project

what do you mean ? Which version and which exact sub package of Telegram.Bot.Extensions, as far as I know, all extensions beside Passport and Login Widget are deprecated. Polling for instance is now part of the Telegram.Bot itself.
Please take a look on the official repo:

I installed telegram.bot.extensions nuget and it only parses to class1
I didn’t know it was obsolete, now I see that it kind of merged into the main repo
Anyway, it looks weird

изображение

For some reason, the “/start” command for new users causes the program to freeze
@nissidis I haven’t tried your wrapper yet, but my attempts have been unsuccessful

I made the patch like the code in the official example.

And the problem I’m experiencing is the transmission of an empty Task (for example, if its skicker or something else)

This raises a bit of a fundamental question, is it possible to do a return or some sort of keep counterpart in the delegates?

изображение

In @nissidis’s wrapper it’s implemented a little differently and it’s works, but still interesting question

@yar I am not sure that I understood what the problem is, but you can for sure define a Delegates type to return (generic or non Type) so you need to filter out the Message or messages you receive (as you do almost in the example). That’s why I proposed the GetUpdates method rather than the StartReceiving, where it is much easier and intuitive to implement a delegate and filter messages on the go. If you still have the repo check the example for multiple bot instances to get an idea.

@nissidis if you look closely to the code you will realize that code after ‘return’ not be executed if condition is not satisfied. There is no equivalent in VL — I’m obligated to create something and push it out. Something like “keep” or “break” equivalent of loops

Otherwise, I agree, another version of this delegate should be used. But it turns out that the direct equivalent of the code does not work.