Tourmaline Changelog#
I will do my best to keep this updated with changes as they happen.
0.30.0#
Added:#
- Full support for Bot API 6.9
- See the official Bot API changelog for a complete list of changes.
0.29.0#
The core functionality of Tourmaline is now auto generated from the official Bot API documentation. This means that Tourmaline will always be up to date with the latest version of the Bot API.
Added:#
- New method set_my_name to change the bot's name. Returns True on success.
- New method get_my_name to get the current bot name for the user's language. Returns BotName on success.
- New Tourmaline::BotName class to represent the bot's name.
- New Tourmaline::InlineQueryResultsButton class to represent a button shown above inline query results.
- New Tourmaline::SwitchInlineQueryChosenChat class to represent an inline button for switching the user to inline mode in a chosen chat.
Changed:#
- Updated Tourmaline::WriteAccessAllowed class to include an optional web_app_name property for the Web App launched from a link.
- Modified Tourmaline::InlineKeyboardButton class to include an optional switch_inline_query_chosen_chat property.
- Updated Tourmaline::CallbackQuery class to include an optional via_chat_folder_invite_link property.
- Modified answerInlineQuery method to accept a Tourmaline::InlineQueryResultsButton instead of switch_pm_text and switch_pm_parameter parameters.
Fixed:#
No bug fixes reported in this diff.
0.28.0#
This release contains major breaking changes. If you currently rely on Tourmaline as a framework you may not want to update.
- Added full support for Bot API versions 6.4, 6.5, and 6.6
- (breaking change) Removed all annotation based handlers.
- (breaking change) Removed the
Handlersnamespace. All handlers now fall directly underTourmaline. - (breaking change) Stripped Tourmaline of all magic. Models no longer have a
clientinstance passed to them, instead we will now rely on theTourmaline::Contextwhich is passed to all handler callbacks.
Examples have been updated.
0.27.0#
- Added full support for Bot API 6.3
- (breaking change) All
is_prefixed properties in models have been replaced with?getters. For instance,is_anonymousis nowanonymous?. - (breaking change)
Client#default_parse_modeandClient#default_command_prefixeshave been made class properties instead of instance properties. - Fixed issues with missing
priorityandgroupproperties on event handlers. - (breaking change)
extra/paginated_keyboardno longer extendsInlineKeyboardMarkup. - Added methods
Client#send_paginated_keyboard,Chat#send_paginated_keyboard,Message#reply_with_paginated_keyboard, andMessage#respond_with_paginated_keyboard. Requires import ofextra/paginated_keyboard. - Fixed broken parts of
extra/routed_menu. - Fixed broken parts of
extra/stage. - Handlers no longer require an instance of
Tourmaline::Client. - Added several new
UpdateActions includingThreadMessage,ForumTopicCreated,ForumTopicClosed,ForumTopicReopened,VideoChatScheduled,VideoChatStarted,VideoChatEnded,VideoChatParticipantsInvited, andWebAppData. - Bot examples have all been fixed
- More, see the official Bot API changelog for a complete list of changes.
0.25.1#
- Added
sender_typemethod andSenderTypeenum toMessage, allowing the user to easily figure out what type of user or channel sent the given message. - Updated docs
0.25.0#
- Removed
Containerclass which was being used to maintain a global instance ofClient. - Added
finish_initmethod to all models, allowing them to contain an instance of theClientthat created them.
0.24.0#
- Added full support for Bot API 5.4 and 5.5
- More, see the official Bot API changelog for a complete list of changes.
0.23.0#
- Added full support for Bot API 5.1 - 5.3
- Fixed some dependencies.
- Added additional classes
ChatInviteLink,VoiceChatStarted,VoiceChatEnded,VoiceChatParticipantInvited,VoiceChatScheduled,MessageAutoDeleteTimerChanged,InputInvoiceMessageContent, andBotCommandScope. - Added
scopeandlanguage_codeoptions toset_my_commandsandget_my_commands. - Added method
delete_my_commands. - More, see the official Bot API changelog for a complete list of changes.
0.22.0#
- Added support for TDLight.
- Added
user_tokenargument toClient.newto support the TDLight user API. - (breaking change) All arguments to
Client.neware now keyword arguments. - (breaking change) Removed
asyncargument from event handlers. All events are now async by default. Async events can be disabled with the-Dno_asyncflag. UpdateHandlernow accepts an array ofUpdateAction, or a single one.- Fixed an issue where
pollalways deletes a set webhook. Now it will only delete the webhook ifdelete_webhookis true.
0.20.0#
- (breaking change) Removed the filters, replaced with new handlers
- (breaking change) Removed Granite specific DB includes from models (also commented out
db_persistence.cr; next update should make persistence better) - (breaking change) Renamed
PagedInlineKeyboardtoPagedKeyboard - Added
RoutedMenuclass for easy menu building
0.19.1#
- Replace broken
Intin unions withInt::Primitive - Make
Helpers.random_stringactually return a random string, not just a number - Change the first run logic in
Stage
0.19.0#
- Added support for
Passport - Added
animated?toSticker - Added several new filters including
InlineQueryFilterandCallbackQueryFilter - Added connection pooling to fix concurrency errors
- Events are now async by default
- Added a new helper class
PagedInlineKeyboard - (breaking change) Moved KemalAdapter to
tourmaline/extra - Added proxy support based on mamantoha/http_proxy
- Added support for multiple prefixes with commands
- Allow changing the log level using the
LOGenvironment variable - Added an
InstaBotexample - (breaking change) Disabled (commented out) DBPersistence for now
- Updated for bot API 4.9
- Added support for the 🏀 emoji, including methods
Client#send_basket,Message#reply_with_basket, andMessage#respond_with_basket - Added
via_botfield toMessage - Added
Stage(importable fromtourmaline/extra) for conversation handling
0.18.1#
- Added ameba checks
- Replaced Halite with
HTTP::Client, resulting in a major speed boost - Rename
persistent_initandpersistent_cleanuptoinitandcleanuprespectively - Remove
handle_errorin favor ofError.from_code
0.18.0#
- Updated polls for Quiz 2.0
- Added new
send_dartmethod
0.17.0#
- KeyboardMarkup
- (breaking change) Replace
Markupclass withKeyboardBuilderabstract class and extend it withReplyKeyboardMarkup::BuilderandInlineKeyboardMarkup::Builder. - Add
.buildmethods toReplyKeyboardMarkupandInlineKeyboardMarkup. - (breaking change) Replace
QueryResultBuilderwithInlineQueryResult::Builder. - Update examples with new
Builderclasses being used. - InlineQueryResult
- (breaking change) Replace
QueryResultBuilderwithInlineQueryResult::Builder. - Add
.buildmethod toInlineQueryResult. - Update examples with new
Builderclasses being used. - Persistence
- (breaking change) Made
Persistencea class rather than a module and updatedHashPersistenceandJsonPersistenceto use it. - Add
persistenceinstance variable toClient - Add
NilPersistenceand make it the default persistence for newClients - Add
DBPersistence
0.16.0#
- Add CHANGELOG
- Add support for Filters.
- Add
usersmethods toUpdateandMessageto return all users included in the same. - Replaced usage of the
strangelogger with the new CrystalLogclass. - Log all updates with
Debugseverity ifVERBOSEenvironment variable is set totrue. - (breaking change) Renamed
FiletoTFileto avoid conflicting with the builtinFileclass. - (breaking change) removed the
Handlerclass and all subclasses. Update handling is now done exclusively with theEventHandlerclass andFilters.
0.15.1#
- Fix bug with event handler that was causing
Onhandlers to run on every update. - Add CNAME file for tourmaline.dev
- Update the logo.
- Add
DiceBotexample.
0.15.0#
Updated to bot API 4.7
- Add
send_dicemethod to client. - Add
BotCommandmodel along withget_my_commandsandset_my_commandsmethods. - Add new sticker/sticker set methods.
- Add
Diceupdate action.