You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Possible candidates to add to the Defaults concept:
tzinfo
We should use Defauts.tzinfo as default instead of UTC … That would mean:
When a job is created without setting tzinfo explicitly, use Defaults.tzinfo
When calling JobQueue._put() with a naive when, use when.replace(tzinfo=defaults.tzinfo)
This would basically not change the current set up, but just put it under the hood
Probably Message.date and all the friends should also use defaults.tzinfo, so basically every datetime instance occuring in the lib.
Arguments of Filters
Filters.command: allow commands anywhere in the text or not
How to make it work: We would need to override those attributes on dispatcher.add_handler somehow. that's pretty much the only time, the filters and the dispatcher can see each other …
Dice.emoji
Only relevant after Api 4.8 #1917. Also discussable, if this really is a good idea, as the emoji attribute of Dice is positional and not optional
ReplyKeyboardMarkup
resize_keyboard
one_time_keyboard
Redesign of default_quote
Right now, default_quote get's passed from getting updates through all objects, whose attributes have a Message attribute and is set as attribute in Message. But as the Message.reply_* methods only work with a bot anyway, we could just access Message.bot.defaults.default_quote.
Possible candidates to add to the Defaults concept:
tzinfo
We should use Defauts.tzinfo as default instead of UTC … That would mean:
when, usewhen.replace(tzinfo=defaults.tzinfo)This would basically not change the current set up, but just put it under the hood
Message.dateand all the friends should also usedefaults.tzinfo, so basically everydatetimeinstance occuring in the lib.Arguments of Filters
How to make it work: We would need to override those attributes on
dispatcher.add_handlersomehow. that's pretty much the only time, the filters and the dispatcher can see each other …Dice.emoji
Diceis positional and not optionalReplyKeyboardMarkup
resize_keyboardone_time_keyboardRedesign of
default_quoteRight now,
default_quoteget's passed from getting updates through all objects, whose attributes have aMessageattribute and is set as attribute inMessage. But as theMessage.reply_*methods only work with a bot anyway, we could just accessMessage.bot.defaults.default_quote.See #1965