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

Implemented handling of inline queries #23

Closed
wants to merge 3 commits into from
Closed

Conversation

fluke
Copy link

@fluke fluke commented Apr 5, 2018

For #7. I've implemented the handling of inline queries. But only for the roll command as of now. And it could probably use some refactoring.

@fluke
Copy link
Author

fluke commented Apr 5, 2018

@treetrnk Can you review this. I'm sure there's a lot to be improved. Just got it working for now.

@treetrnk
Copy link
Owner

I'm hoping to take a look at this soon. Thanks for the PR!

@fluke
Copy link
Author

fluke commented Apr 16, 2018

No problem. Been using this bot fairly regularly but often outside of my DnD group I'd like to roll for something without adding the bot.

I don't usually write Python so I assume it's a bit messy.


#Get command
self.is_command = False
if len(self.query_string) > 0:
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would probably be a good idea to add the regex match here. It evaluates all intermediates in writing an equation. We can avoid evaluation of equations not matching the formula.

@treetrnk
Copy link
Owner

I was unable to get this pull request to work back when it was submitted. I didn't have a lot of time to work on it then though. Since then, I have updated the codebase to use python-telegram-bot. Feel free to submit another pull request to work with the new version and I'll take a look.

@treetrnk treetrnk closed this Dec 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants