Skip to content

v2.0.0-20231228.215524

Pre-release
Pre-release
Compare
Choose a tag to compare
@andregasser andregasser released this 28 Dec 22:41
· 69 commits to master since this release
6960044

📢 Overview

This snapshot brings many new features and functionalities, but also various breaking changes. One of the highlights of this release is certainly the refactoring of the streaming API which has now been implemented based on the WebSocket protocol. Please read the “Breaking Changes” section carefully to understand where you should expect changes to your code. Happy holidays! 🎄

⭐ New Features

🐞 Bug Fixes

  • Propagate exceptions occurring during client instantiation by @PattaFeuFeu in #353
  • Remove defaults for limit parameter + do not verify values by @PattaFeuFeu in #367

📔 Documentation

🔨 Dependency Upgrades

⚡ Breaking Changes

Streaming API WebSocket Refactoring, introduced in #383

With the replacement came loads of breaking changes. I’ve replaced the previous Handler and Shutdownable with a leaner callback and an extension of Closeable, so now the signatures, while similar, are actually quite different for callers.

It’s no longer necessary (or even possible) to call useStreamingApi when building the MastodonClient.

Please check our updated Usages section about the streaming API or one of the following samples to see how to utilise the streaming API:

Mastodon Client Builder, introduced in #353

MastodonClient.Builder#build may now throw a BigBoneClientInstantiationException.

ListMethods#createList Changes, introduced in #379

ListMethods#createList parameter repliesPolicy now is null by default and is defined as nullable. Likely won’t break anything, but just in case…

OAuthMethods Parameter Changes, introduced in #370

OAuthMethods#getOAuthUrl: scope moved from second to third parameter, switching places with redirectUri, and also became optional (=> nullable).

Rx Return Type Changes, introduced in #371

RxFollowRequestMethods#authorizeFollowRequest and RxFollowRequestMethods#rejectFollowRequest now return Single<Relationship> instead of Completable.

Update Scopes Used in OAuth, introduced in #382

  • Scope constructor can no longer be called without explicitly enumerating scopes that should be requested.
  • Scope.NAME enum has been replaced with hierarchically arranged scope definitions in the class. Example: Scope.Name.READ becomes Scope.READ.ALL.
  • Existing FOLLOW scope has been removed. Use individual child scopes of READ and WRITE instead.
  • Existing ALL scope has been removed. Use individual scopes necessary for your use case instead.

Exception Handling Changes, introduced in #367

The following no longer throw or declare an IllegalArgumentException, so any try/catch can be removed:

  • DomainBlockMethods#getDomainBlocks
  • EndorsementMethods#getEndorsements
  • FollowedTagMethods#viewAllFollowedTags
  • SuggestionMethods#getSuggestions

❤️ Contributors

Thank you to all the contributors who worked on this release:

Full Changelog: v2.0.0-20231125.173242...v2.0.0-20231228.215524