Skip to content

Commit 44ce120

Browse files
committed
Add migrating docs for cache/channels
1 parent 8c2a4b3 commit 44ce120

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

docs/getting-started/migrating.rst

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,22 @@ started is with :class:`twitchio.AutoClient` and :class:`twitchio.ext.commands.A
255255
Cache and Channels
256256
===================
257257

258-
TODO
258+
Previous versions of TwitchIO used caching mechanisms to store ``"Connected Channels"`` and the ``"Chatters"`` associated with those channels.
259+
260+
Due to the removal of ``IRC`` this is no longer necessary and TwitchIO only does very limited caching where needed.
261+
262+
``EventSub`` events that have an associated channel will contain a ``broadcaster`` attribute which is a :class:`twitchio.PartialUser`,
263+
and is the channel the event originates from and can be used to perform actions on the channel/broadcaster.
264+
265+
If you are using a :class:`~twitchio.ext.commands.Command`, a :class:`~twitchio.ext.commands.RewardCommand` or anywhere
266+
:class:`~twitchio.ext.commands.Context` is available, consider using the helper methods and attributes available on
267+
:class:`~twitchio.ext.commands.Context`.
268+
269+
**Removed:**
270+
271+
- ``Client.connected_channels``
272+
- ``Client.get_channel()``
273+
259274

260275
Twitch Identifiers
261276
===================

0 commit comments

Comments
 (0)