This repository has been archived by the owner on Jun 30, 2022. It is now read-only.
Releases: litaio/lita
Releases · litaio/lita
v4.8.0
Includes all the changes in v4.8.0.beta1 to make Lita work better with the latest version of Ruby and the latest gems.
Features:
Lita.default_locale
is added to setI18n.default_locale
, which should be preferred toLita.locale
because it affects all threads.config.robot.default_locale
added as a configuration attribute, which should be preferred toconfig.robot.locale
for the same reason.Lita.default_locale
will be set based on the environment variableLANG
, just asLita.locale
has previously.
v.4.8.0.beta1
This is a maintenance release to address Ruby version and dependency issues that have cropped up in the years since the v4.7.1 release. It is released as a beta because it has not been thoroughly tested with other gems in the Lita ecosystem. If you use this and find any compatibility issues or bugs introduced since v4.7.1, please report them via the issues page.
Updates:
- The minimum Ruby version is now 2.5.
- Lita now requires the following versions of its dependencies:
- bundler: >= 2.0
- faraday: >= 1.0
- http_router: >= 0.11
- ice_nine: >= 0.11
- i18n: >= 1.8
- multi_json: >= 1.15
- puma: >= 4.3
- rack: >= 2.2
- rb-readline: >= 0.5
- redis-namespace: >= 1.7
- thor: >= 1.0
4.7.1
Fixes:
- An upper bound on the version of Rack Lita depends on has been added so Lita can still be installed on Ruby 2.0. (Rack 2.0 requires Ruby 2.2.)
4.7.0
Features:
Lita::Message#extensions
has been added as a place for plugins to store arbitrary metadata associated with a message.
4.6.1
Bug fixes:
- Fixed a regression from v4.6.0 that caused the
replies
method in RSpec examples to always return the value it had when it was first called.
4.6.0
Features:
- Adapters can now implement chat-service-specific functionality by implementing
Lita::Adapter#chat_service
. This is available to handers throughLita::Robot#chat_service
. See the Slack adapter for an example. - A new built-in adapter,
Lita::Adapters::Test
has been extracted from theLita::RSpec
internals and can be used to build integrations for other testing frameworks.
Improvements:
- The
send_message
andsend_command
helper methods in RSpec now accept a boolean:privately
option for marking the message as private.
Bug fixes:
- Exceptions raised in event callbacks now only crash the event handler and not the robot.
4.5.0
Features:
- Custom helper methods for templates. Make methods available to a template by using the new
render_template_with_helpers
method, which lets you pass in an array of modules to extend onto the template evaluation context. - New event:
:message_dispatched
, fired every time an incoming message matches a handler's chat route. The payload includes the message, the route, the handler class, and the robot. - New event:
:route_authorization_failed
, fired whenever an incoming message fails to match a route because the sending user was not in the proper authorization group. The payload includes the message, the route, and the robot.
Improvements:
- Lita is now tested against JRuby 9.0.0.0 and Rubinius 2.x. It works with both implementations, with the exception of the daemonization feature on JRuby. This feature is being removed in Lita 5 anyway, so anyone using it now should migrate to a dedicated process manager.
- The
send_message
andsend_command
helper methods in RSpec now take a:from
option to specify the source room. - New convenience methods to reduce Law of Demeter violations:
Lita::Message#room_object
,Lita::Message#private_message?
,Lita::Response#private_message?
, andLita::Response#room
. - Less verbose
#inspect
output forLita::Robot
objects, making test failure output easier to read. - The line that registers a plugin with the global
Lita
registry in generated plugin files now usesself
so it's less painful if you decide to rename the plugin. - The http_router gem was finally updated so Lita no longer monkey patches it.
- Many small documentation and code quality improvements.
Bug fixes:
- Messages are now more strict about being interpreted as commands. If the message is directed at the bot by using its mention name, it must include a space (after an optional comma or colon) before any additional text. This prevents messages that start with words that happen to be the same characters as the bot's mention name from being accidentally treated as commands. This behavior does not apply to messages addressing the bot via its alias, which is intended to be a single character like a slash, exclamation point, or period.
4.4.3
- Fixed: Rooms are only persisted to Redis if they can be verified by the existence of a
Lita::Room
object. - Fixed: A few missing and incorrect pieces of API documentation.
4.4.2
- Fixed:
Lita::Robot#persisted_rooms
is now public.