Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Telegram bot /info should return exactly what UpdateLiveStats does - any more ideas #5236

Closed
Lntnam opened this issue Sep 6, 2016 · 13 comments

Comments

@Lntnam
Copy link

Lntnam commented Sep 6, 2016

I've been using Telegram bot and I'm in love with it. I can totally replace the Web UI for keeping track of what the bot's doing, and where.

Here's my two cent : /info should return more relevant data - the best bet is to be exactly what people have set up for "UpdateLiveStats", instead of the current static set of info. For example, the number of catches over the past 24 hours wouldn't be helpful in any circumstance, with the daily catch limit on.

Like-wise, /inventory (to be added) should works as same as "UpdateLiveInventory";
/show_best would show you your best pokemon

Furthermore, certain commands can be issued to the bot, if possible

  • /transfer would trigger transfer pokemon before the threshold is reached
  • /return_poly would trigger returning to the start location using polyline walker, ignoring all path & move config.
    and much more if it is possible for the Telegram to control other tasks.

In fact, Telegram can even become our own app client with push notification for events, and awaiting for our actions.

@rawgni
Copy link
Contributor

rawgni commented Sep 6, 2016

yep. the code needs refactoring.

@avexus
Copy link

avexus commented Sep 6, 2016

I used it. At first it was good. Then, too many messages, so i disabled it.
It could be used to control bots too, because the telegram can send message to bot and bot can read it.
The bot should handle "unknown messages/commands" error though.

@DBa2016
Copy link
Contributor

DBa2016 commented Sep 8, 2016

Parts of this "issue" (it is a feature request, by the way, please update the title) have already been implemented in #5238 (merged into dev already; you can subscribe to whatever events you like, including log_stats) and in #5274 (adds display of top X pokemon, plus some backend preparations for pokemon manipulations).

Yes, I liek the idea of having Telegram as an own kind-of-frontend.

Actually, this all logic should go into a base class, inherited by Telegram, Discord etc etc.

Hell, old-school guys could even use IRC or FidoNet to control the bot...

@Gobberwart
Copy link
Contributor

@DBa2016 Yes it should. Maybe I'll look into it tomorrow.

@Lntnam
Copy link
Author

Lntnam commented Sep 8, 2016

Strange, I've just tried to pull from dev 1 hour ago and there's no changes. Maybe it's been updated since yesterday, but I can't see any change in sample config file, and Telegram is not notifying anything now.

@DBa2016
Copy link
Contributor

DBa2016 commented Sep 8, 2016

@lntn : #5274 is waiting to be merged yet, so "/top" does not work yet. For notification configuration, please look at the telegramtask.md, you need to subscribe to the events you want notifications about.

@Lntnam
Copy link
Author

Lntnam commented Sep 8, 2016

@DBa2016 thanks for the PR.

by In order to subscribe to a certain event, e.g. to "no_pokeballs", you simply send the/subcommand as follows:, does it mean that we will need to subscribe again every time the bot started? Or do you keep the subscription in some files? If subscription is just temporary then I'd suggest to have a config line for that instead of manual subscription

@th3w4y
Copy link
Contributor

th3w4y commented Sep 9, 2016

man this will require quite some work...!

/return_poly would trigger returning to the start location using polyline walker, ignoring all path & move config. and much more if it is possible for the Telegram to control other tasks.

@javajohnHub
Copy link
Contributor

With the recent merge can this now be closed?

@javajohnHub
Copy link
Contributor

Nevermind the features you asked for havent been implemented.

@Lntnam
Copy link
Author

Lntnam commented Sep 16, 2016

I have not tried it yet, but thanks you.

@Lntnam Lntnam closed this as completed Sep 16, 2016
@Lntnam Lntnam reopened this Sep 17, 2016
@Lntnam
Copy link
Author

Lntnam commented Sep 17, 2016

@javajohnHub I've pulled the latest dev branch few hours ago and /info still giving the same old stuff, like number of pokemon caught in the past 24 hours.

@javajohnHub
Copy link
Contributor

So even though you can subscribe to that data....you would still like a command to get updatelivestats?

@Lntnam Lntnam closed this as completed Sep 17, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants