v0.4.0
Release v0.4.0
Version 0.4 introduces auto-reconnect for RyverWS
real-time clients! Minor breaking changes were introduced since 0.3.2. Please see the list below for changes.
For an example on how to use the new connection features, see Realtime Quickstart or the Example Usage on the homepage on Read the Docs.
Notable Changes (Since v0.3.2.post1)
Breaking Changes
- To allow for re-connecting,
RyverWS.close()
will no longer causeRyverWS.run_forever()
to return. Instead,RyverWS.terminate()
was introduced to makerun_forever()
return. (2006da9) - Previously deprecated
@RyverWS.on_error
decorator was removed. (d4e36bd) - The orders of arguments for some methods taking attachments and a
Creator
were switched for consistency so that the attachment parameter always comes first (except insend_message()
). (0b5bc03) GroupChatMember
'sas_user()
method has been made async because it needs to fetch additional information. This could be considered a bugfix. (11ca311)
New Features
RyverWS
realtime sessions can now auto-reconnect (seeRyverWS.set_auto_reconnect()
andRyver.get_live_session()
's newauto_reconnect
parameter). (823a35b)- New decorator
@RyverWS.on_reconnect
for defining a callback to be called when auto-reconnect succeeds. (d4e36bd) - All methods that deal with files (e.g. attaching to a message, a topic or a task) can now take
File
objects and not justStorage
objects. (4739637) Ryver.get_object()
now supports getting a list of objects. (e5cdccb)- All
send_
and connect functions inRyverWS
now have an optional timeout parameter that defaults to 5 seconds. (2fdebe6) - Most classes (
Creator
,TaskTag
, all classes inheriting fromObject
, all WS message classes) now use__slots__
for memory savings and faster attribute access. (4e575ab) - Classes inheriting from
Object
are now all hashable (and hash to their IDs). (4e575ab) - Most classes now have a
__repr__()
implementation. Objects with names will have their names shown in their__repr__
, and some other classes such asMessage
s will have even more information. (ab3f9f9, 0e9639c) Ryver.get_groupchat()
now take additional arguments to specify whether to search teams or forums.Ryver.get_team()
andRyver.get_forum()
were introduced (e1903c7).- Add methods
GroupChat.join()
andGroupChat.leave()
for joining and leaving forums and teams. (d14ccca)