Releases: nxtlo/aiobungie
Releases · nxtlo/aiobungie
Redesign, Bungie user and Destiny members implementation.
Breaking changes
- Renamed
http.py
torest.py
. - Renamed
HTTPClient
toRESTClient
. - Renamed
impl.py
totraits.py
. - Renamed
serialize.py
tofactory.py
- Renamed The main client protocol
RESTful
toClientBase
. - Renamed
Deserialize
class toFactory
. - Renamed
Client.http
toClient.rest
. - Renamed
JsonDict
andJsonList
toJsonObject
andJsonArray
. - Renamed
ProfileComponentImpl
toProfileComponent
. clans.ClanOwner()
is removed in-replace ofclans.ClanMember()
.user.User
attributes has been removed and replaced with two new ones,bungie
which returnsuser.BungieUse()
and destiny which returnsuser.DestinyUser()
objects.- Clan member
join_date
,is_online
,last_online
attributes currently returnsNone
due to a Bug. - Removed
human_timedelta
fromtime.py
and property from all objects that had this method. - Removed
as_dict
method from all objects that had this method. - Objects that were decorated with
attr.s
are now decorated withattr.define
- Objects that has a
.icon
or.picture
attributes now returnassets.MaybeImage
instead ofassets.Image
which returns anImage.partial()
incase the object was Undefined or didn't have that field. - Removed
ClanMember.net
property and converted to a class attr. - Removed
attr.s
decorator from abstracted classes. player.Player
no longer inherit fromUserLike
. Also this object is scheduled to be removed and replaced withuser.DestinyUser
in0.2.5
Stable release.db.py
which as an sqlite databse associated withManifest
was removed for the user themselves to implement.Manifest
now only provied a method to download it and all other methods was removed. Note that this is still buggy and should be fixed with0.2.5
release.
Features
- You're now able to use
rest.RESTClient()
for direct low-level interaction with the API which results to.- No Hight-Level, Object-orianted usage.
- All returned data are pure json objects from the API.
- No runtime assertions.
- No Deserialazation. Meaning you'll have to implement you own methods to get your desired results.
- Faster. Since no third party classes, assertions and deserializing happening in the backend.
why? Some times people don't need high level client concepts introduced to their applications,
So we give them freedom to implement it themselves :)
- Added
interfaces/**
module which include abstracted interfaces for objects implementation. - New class
clans.ClanConversation()
that implementsGroupV2.GetGroupOptionalConversations
. - New class
clans.ClanAdmin()
that implementsGroupV2.GetAdminsAndFounderOfGroup
. - New class
clans.GroupMember()
that implementsGroupV2.GetGroupOptionalConversations
andGroupV2.GetPotentialGroupsForMember
. - New class
user.PartialBungieUser
that implements partial bungie net user information. - New class
user.BungieUser
which wasuser.User
. - New class
user.DestinyUser
which implement a destiny user memberships. - Modified class
user.User
is now modified to return only two attributes which contains bothbungie
anddestiny
user memberships. - New
ClanMemberType
enum for clan memberships types. - New trait
Serializable()
to add serialize signature to theClientBase()
protocol. - New
rest
property to theClient
that returns the rest client. - New
helpers.UndefinedType()
undefined type for data that will results toUNDEFINED
,UndefinedOr[T, UndefinedType]
which returns aT
orUNDEFINED
ifT
is None. - New
helpers.get_or_make_loop()
function that get or creates a new asyncio event loop - New
Client.search_users()
method which implement theUser.SearchByGlobalNamePrefix
. - New
Client.fetch_membership_from_id()
method that implementsUser.GetMembershipDataById
. - New
Client.fetch_clan_conversations()
method that implementsGroupV2.GetGroupOptionalConversations
. - New
Client.fetch_clan_admins()
method that implementsGroupV2.GetAdminsAndFounderOfGroup
. - New
Client.fetch_groups_for_member()
method that implementsGroupV2.GetGroupsForMember
andGroupV2.GetPotentialGroupsForMember
- New
ApplicationOwner.fetch_self()
method that returnsuser.BungieUser()
object of the app owner. - More methods under the almost all objects to make them more flexible.
JsonArray
now takes any type of object instead of onlydict[..., ...]
.Client.fetch_user()
now returnsuser.BungieUser
instead ofuser.User
.Client.fetch_player()
now returnstyping.Sequence[user.DestinyUser]
instead ofplyaer.Player
.
Bug fixes
- Fix a bug where clan member attrs are duplicate.
- Fix a bug where the rest client wasn't retrying on
5xx
errors.
Meta
- Separate CI tests from each other.
0.2.5b7 release.
Break changes
This release includes huge break changes. Like classes renames. functions removed and different behavior to match the new bungie api design.
- Renamed
impl.BaseClient
main client protocol toimpl.RESTful
- Removed
Client.fetch_user_from_id
since bungie removed this method. Client.fetch_user_from_id
is nowClient.fetch_user
Client.fetch_player
Now requires the full name bungie name with its code, i.e.,Fate#1234
- Removed some class attrs from
crate.User
repr. - The
HTTPClient
now raises an error before continuing the request if the API was down. - All
id
class attrs that used to return a str object of the id now returns an int object, i.e., '1234' -> 1234. - Removed
PartialUser
ABC since it was really slowing things up for no reason.
Features
- New class attr
unique_name
that returns the Bungie user/player's unique name, i.e,Fate#1234
. - New class attr
code
that returns the bungie user/player code, i.e,1234
. - Optimized HTTP requests speed.
type
parameter is now optional to pass onClient.fetch_player
.- Added
ClanMember.types
that returns all membership types for clan member. - Added
Player.types
that returns all membership types for player. - Added the version addition to the docs.
- Removed overload methods
__int__
and__str__
on all userlike crates and added them to the baseUserLike
object.
Bug fixes
- Fixed a bug where bungie won't allow
301
without usingwww.
redirect forSearchDestinyPlayer
endpoint.
0.2.5b6 release.
Breaking changes
HTTPClient
will now raiseOSError
if the Bungie API is shutdown instead of making the request and raising an Unknown error.- Moved package metadata to
_info.py
. - Added an aiobungie client
User-Agent
key as an http kwarg.
Features
- Bungie Season basic implementation.
- Removed type hints from
__slots__
since mypy is causing errors. - Finished All coverage for the
User
endpoints except one which will be finished by next relese. - Added a code spelling fixes to nox tests which requires the
codespell
module. - Improved Docstrings for all methods.
Bug Fixes
- Fixed a bug where
joined_at
,last_online
,group_id
andis_online
attribs were the same for all clan members inClient.fetch_clan_members()
0.2.5b5 pre-release.
Breaking changes
- objects folder name changed to crate
fetch_activity()
now works but still not stable.fetch_activity()
parameters names changed fromuserid
,charid
,memtype
tomembed_id
,character_id
,membership_type
.- Removed useless
Attributes
docstrings from all crates.
Features
- A very basic re-implementation of the
Activity
/ crate. - A new crate
PostActivity
that returns post activity data. - A new method
Client.fetch_hard_types()
which returnsHardLinkedMembership
crate with the user's hard linked data - A new method
Client.fetch_post_activity()
which returns
Bug Fixes.
- Fix relative import errors for some of the modules that won't work without
typing.TYPE_CHECKING
.
0.2.5b4
Breaking changes
UserCard
class name changed toUserLike
.http.PreLock
class for thread safety for htto requests.- All Entitiy definitions now inherit from the
Entity
main abc. - All
as_dict
methods has changed into@properties
.
Features
- Version bump to
0.2.5b4
ClanMember
object is fully implemented.- You can now fetch clan members from the
Clan
object usingawait fetch_member("NAME")
andawait fetch_members()
for the clan members will return all members in a mutable dict
contains a clan member name and a their id as the value. example:{"Foo": 19823791283, "Bar": 12391203, ...}
. InventoryItem
entity which'sDestinyInventoryItemDifinition
is implemented but you might find some buggy stuff.- Added a
fetch_inventory_item
method which returns anInventoryItem
entity.
Bug Fixes.
- Minort http error handling.
- The main
fetch()
http method is now decorated withtyping.final
.
0.2.5b3 release.
Breaking changes
Profile
Component reimplementation.Activity
can not be used currently.character
variable has been removed from theProfile
component with an easier access for the characters. see Features.types
module has been deleted since we're using class attrs.
Features
Profile
component now has 5x faster responses and safer.- Added a
PartialProfile
and 3 new async methods toPartialProfile
.titan
,warlock
,hunter
. All three returns the selectedCharacter
object instead ofcharacter
class var. - Added a new method in
Time
.format_played
that formats the total played time for characters and players. Profile
object is now serialized.Character
object is now serialized.- Added a new runtime protocol
RESTful
for accessing and making rest methods from other objects. - New Errors
Minor Changes
- Better http error handling.
- All http errors now derives from
HTTPException
Bug Fixes.
Profile
component fixes and error handling.
0.2.5b2
Breaking changes
meta.py
has been moved toaiobungie/ext
as a aiobungie extension.- Class
RedisCache
has been renamed toCache
. HTTPClient.fetch()
now has two more paramaters forManifest
client bindings.
Features
- Manifest now auto-checks for the version and warn if there's a new one.
Minor Changes
- Asserting responses before returning them for catching bugs.
New Modules
db.py
for Bungie manifest database.
Bug Fixes.
HTTPClient
now only raises the error message instead of the whole data.- Better error handling for the manifest.
- README fixes for the python versions tags.
0.2.5b1 release.
Breaking changes
- types module being cleaned. Why? because i'm switching from
TypedDict
to attrs module and ABCs, which's way cleaner and faster. - A new module
serialize.py
for deserializing objetcs then passing them to the http request for cleaner and faster access methods. - a new module
impl.py
which will include all typing protocols and implementaions of other clients. - Now all user like objects will inherit from
UserCard
abc. i.e.,Player
,ClanOwner
. - OAuth2 is now dropped since my focus on this lib is not OAuth.
human_time
property is renamed tohuman_timedelta
.Client
now inherits from the base runtime protocolimpl.BaseClient
.
Features
- Version Bumped to Beta 1 and ready for testing.
- Added
BaseCache
implementation protocol for cache access fromBaseClient
. - Objects Speed optimization.
- Redis Hash cache now can be accessed from
Client
for cache testing purposes. - New return types in
helpers.py
,JsonDict
andJsonList
. http.py
requests now returnJsonDict
orJsonList
depends on the returned data.
Returned are now deserialized inclient.py
.- Removed all types except
character.py
andprofile.py
andactivity.py
which will be deleted and moved as anabc
classes in 0.2.5 Stable release. - Added a
.link
property which will return the url of the objects, this can be aClanOwner
,ApplicationOwner
or any User like object. - Added
BUNGIE
enum as aMembershipType
New Modules
impl.py
includes every base client runtime protocol.serialize.py
includes data and objects deserialazition.
Removed
oauth.py
already mentioned above.security.py
was a helper module foroauth.py
.
Paused
Manifest
is currently not being worked on until i finish all objects implementation.
Bug Fixes.
HTTPClient
was not raisingHTTPException
on http errors.
0.2.5a4
Breaking changes
Features
- Better Error messages on http.py and all objects.
- Added examples.
- Added a new exception for handling Components using
ComponentError
- Added
__aenter__
forasync with
support. - Supports Python 3.10dev
Bug Fixes.
Player
returnsTypeError
when a player is not found and not raising the actual error.- Removed
characters
fromas_dict
method onProfile
because it was causing errors when fetching a profile component.
Alpha3 0.2.5
Breaking changes
- utils folder name changed to internal
- All enums starts with Destiny* changed to its name Only i.e.
- DestinyClass -> Class
- DestinynGender -> Gender
- etc.
Features
- Profile Implementaion and types
- base urls are now in
url.py
- Added
as_dict()
method which returns a dict object of the class to all objects. fetch_profile()
function currently works for the profile and character component only- More enums
- The
meta.py
module wich includeManifest
class stuff now works. - all
__repr__()
methods now return the string of the enums instead of theint for better readability. - docs are now in master.
Bug Fixes.
HTTPClient
returning text during 404 errors instead of raisingNotFound
- General
Character
object fixes.