@@ -6,6 +6,72 @@ Changelog
66This page keeps a fairly detailed, human readable version
77of what has changed, and whats new for each version of the lib.
88
9+ v0.3.0
10+ -------
11+ Bug Fixes
12+ ~~~~~~~~~~~
13+ - All iterators have been fixed in python 3.7
14+ - :ref: `on_clan_member_join ` will now fire events correctly
15+ - Properly parse HTML errors thrown by CloudFlare
16+ - Accessing the ``League.badge `` attribute has been fixed
17+ - Clan events now sleep for the correct interval
18+ - ``WarMember.town_hall `` has been fixed
19+ - The API used to fetch IP has been changed (##19) to https://api.ipify.org/
20+ - Ensure the clan is in war before trying to find prep time (##21)
21+
22+ New Things
23+ ~~~~~~~~~~~~~
24+ - Check out the `Cache ` tab in sidebar for a how-to work with the new cache. It still works out of the box!
25+ - You can now call utils with ``coc.utils.X ``
26+ - All events now have callbacks as an extra layer of security to stop them from failing.
27+ - New Properties: ``Clan.share_link `` and ``Player.share_link ``.
28+ - Add ``utils.maybe_sort() `` as an easy tool to sort clan war attacks.
29+ - All attributes that were prefaced with a ``_ `` to dictate being iterables have been changed to be prefixed
30+ with ``iter ``, ie. ``_attacks `` becomes ``iterattacks ``.
31+ - Rename ``SearchPlayer.level `` to ``SearchPlayer.exp_level `` - keep in line with API naming.
32+ - Default value can be passed to ``BasicPlayer.league ``; defaults to `None `
33+ - Default value for ``SearchPlayer.builder_hall `` is 0.
34+ - New Error: `PrivateWarLog `:
35+
36+ - Subclass of `Forbidden ` and a special case for when a 403 is thrown from trying to access war info for a clan with a private war log.
37+ - Redirect all `Forbidden ` thrown errors in get_WARS methods to throw `PrivateWarLog `
38+
39+ - A valid operation is to do either:
40+
41+ .. code-block :: python3
42+
43+ try:
44+ await coc.get_current_war(...)
45+ except coc.Forbidden:
46+ pass
47+
48+ # or:
49+
50+ try:
51+ await coc.get_current_war(...)
52+ except coc.PrivateWarLog:
53+ pass
54+
55+ - ``EventsClient.add_X_update `` now accepts either a string or iterable.
56+ - New Method: ``client.remove_events() `` which works in the same way as ``client.add_events() ``
57+ - Speed up `utils.get `
58+ - New Events:
59+ - :ref: `on_player_clan_join ` - when a player joins a clan
60+ - :ref: `on_player_clan_leave ` - when a player leaves a clan
61+ - :ref: `on_player_clan_level_change ` - when a player's clan's level changes
62+ - :ref: `on_player_clan_badge_change ` - when a player's clan's badges change.
63+ - `on_client_close ` which is dispatched upon closing the client
64+
65+ - Rename `x_achievement_update ` --> `x_achievement_change ` for consistency
66+ - Add ``localised_name `` and ``localised_short_name `` attributes to :class: `League ` and :class: `Location `
67+ - These have no effect at present.
68+
69+ Documentation
70+ ~~~~~~~~~~~~~~~
71+ - Lots of the docs have had tidy-ups, with 2 new how-to's dedicated to Cache and the Events Client.
72+
73+
74+
975v0.2.0
1076--------
1177EventsClient
0 commit comments