Releases: mathsman5133/coc.py
Releases · mathsman5133/coc.py
v3.9.1
v3.9.0: February 2025 Update
Additions:
- Added the new Metal Pants & Snake Bracelet equipment to coc.EQUIPMENT
- Added the new Troop Launcher Siege
- Updated static data & enums for the February 2025 update
- Changed from ujson to orjson for improved performance and future-proofing
Bugs Fixed:
- Fixed a bug that would cause coc.Client.get_membersto return an empty list
v3.8.4
v3.8.3 Realtime kwargs bug fix
v3.8.2
Bugs Fixed:
- Fixed a bug with :func:coc.Client.get_current_warthat caused it to not fetch the correct current CWL war
v3.8.1
Bugs Fixed:
- Fixed a bug with **kwargs in coc.Client functions that caused duplicated values
v3.8.0
Additions:
- Added the new Lavaloon & Electro Boots equipment to :class:`coc.EQUIPMENT`
- Added :func:`coc.Client.get_equipment`
- Added new Minion Prince hero to :class:`Hero`
- Updated static data & enums for TH17
- Added explicit cache control to every endpoint
   - Use :attr:`coc.Client.lookup_cache` (default `True`) or pass it as a kwarg to API calling methods (default `None`) to control whether a lookup in the cache is performed. If `None`, it defaults to :attr:`client.lookup_cache`.
   - Use :attr:`coc.Client.update_cache` to control whether the cache is updated after a request.
   - Use :attr:`coc.Client.ignore_cached_errors` to specify status codes to ignore in the cache. For example, cached `404 Not Found` responses can be bypassed by setting `ignore_cached_errors=[404]`.
- Moved `cls` functionality from `EventClient` to `Client` via :func:`coc.Client.set_object_cls`
   - Previously, `cls` could only be set at the `EventClient` level and applied to every event automatically. Now, it can be set directly in the normal `Client` when initializing and can override the API call if needed. This eliminates the need to change `cls` for every individual API call.
Bugs Fixed:
- Fixed a bug that would cause the first war of CWL to not appear while it was in prep & caused an index error appearing in output/logs
- :func:coc.Client.verify_player_tokenrequests are no longer cached
v3.7.2 Enable gzip & deflate compression
Additions:
- Supercell enabled compression for all endpoints. coc.py will now request compression for every request.
v3.7.1: Merge pull request #244 from mathsman5133/release/3.7.1
Additions:
- Added the new Magic Mirror equipment to coc.EQUIPMENT
- updated static data
Bugs Fixed:
- Fixed a bug that would cause coc.py to break if a request was sent with an empty string for a tag
v3.7.0: June 20204 Update
Additions:
- Added inheritance of classes into the docs to make it easier to see what classes inherit from others.
- Added the new BattleModifiertoClanWar.battle_modifierandClanWarLogEntry.battle_modifier.
- Added the new troop and equipment in June 2024 update to the static data.
Changes:
- Changed the way the ClanWarandClanWarLogEntryclasses handles thestateandresult
 attribute, respectively. It now returns aWarState/WarResultenumeration object instead of a string
 to allow better type hinting and easier comparison.
- Updated the static data to reflect the June 2024 update changes.