Releases: supabase-community/supabase-kt
3.2.2
Changes
Core
- Update to Ktor to version
3.2.2
- Fix Sketch integration not correctly publishing
There is now a Sketch integration for those using Sketch!
Postgrest
Auth
- Fix IMPLICIT OAuth flow on Desktop targets by @jan-tennert in #1005
3.2.1
Info
The plugins have been moved to their own repository by @jan-tennert in #955
- I added a Sketch integration, however there were some problems publishing this plugin, I'll fix it soon
- In the future the versioning for the plugins will be separate from the main modules, I'm still deciding whether I just detach the plugins from the publishing process or find another solution. Nothing should have changed for now
If you encounter classpath errors, manually add the main modules you're using (e.g., Auth) as dependencies, rather than relying solely on plugin dependencies (e.g., Compose Auth). This will be resolved in the next version.
Changes
Core
- Update KotlinX Datetime to version
0.7.1
by @jan-tennert in #995 - Update Ktor to version
3.2.1
Functions
Realtime
- Add presence enabled flag by @jan-tennert in #996
New Contributors
3.2.0
Changes
Note: KotlinX Datetime Version 0.7.0
is not compatible for now! An update to KotlinX Serialization is required.
All modules
- Update to Kotlin
2.2.0
- Update to Ktor
3.2.0
- Don't swallow
CancellationException
by @sproctor in #895 - Only catch serialization exceptions in
bodyOrNull
by @jan-tennert in #904 - Fix simple warnings by @sproctor in #915
- Use Dispatchers.IO by default on multi-threaded platforms by @sproctor in #905
- Configurable default dispatcher
SupabaseClientBuilder#coroutineDispatcher
, defaulting toDispatchers.IO
on supported targets. - Deprecated
AuthConfig#coroutineDispatcher
, replaced by the new client wide dispatcher.
- Configurable default dispatcher
Core
- Add new standard headers by @jan-tennert in #927
Auth
-
Add new event system, add support for error code in OTP links by @jan-tennert in #912
supabase.auth.events.collect { when(it) { is AuthEvent.OtpError -> { println(it.errorCode) } is AuthEvent.RefreshFailure -> TODO() } }
New event system which exists next to the
sessionStatus
, but works independently. Currently there are two events:AuthEvent.OtpError(...)
- will be emitted if an error code was found in a OTP link (deeplink on Android/iOS, URL on JS and Desktop)AuthEvent.RefreshFailure(cause)
- will be emitted if a session refresh failed (regardless if the session is still valid)
This PR also changes the
SessionStatus.RefreshFailure(cause)
:- The
cause
parameter/property is deprecated (use the event for the cause) - This status will only get set, if the session expired.
--> If a refresh failed, an event will always be emitted, but the session status will only get updated if the session also expired. Planning to rename the status in the future to something like
SessionStatus.NeedsRefresh
Additional changes:
- Error related parameters will now be removed from the history when used
-
(JS, WASM JS) Add an option to disable automatic url checking by @jan-tennert in #96
install(Auth) { disableUrlChecking = true //Default: false }
-
Add support for providing a custom url launcher by @jan-tennert in #933
You can now provide a customUrlLauncher
for opening URLs in the OAuth flow:install(Auth) { urlLauncher = UrlLauncher { supabase, url -> println("Opening URL: $url") } }
-
Deprecate NativeSignInResult.NetworkError as it isn't used by @jan-tennert in #952
-
Deprecate minimalSettings in favor of minimalConfig by @jan-tennert in #916
-
Fix null result when sign up with Email provider by @hieuwu in #922
- Fix OAuth server listener resuming coroutine twice by @jan-tennert in #893
A Desktop app using OAuth should no longer produce an exception when exiting the app after usingsignInWith(OAuthProvider)
- Add missing error codes by @jan-tennert in #909:
EmailAddressInvalid
,Web3ProviderDisabled
,Web3UnsupportedChain
- (JS/Wasm JS) Fix exception on non-session hash parameters and only consume used parameters by @jan-tennert in #911
Previously, all URL parameters / hash parameter were removed after successfully authenticating, this is no longer the case. - Fix session expiration check by @jan-tennert in #913
The session will now also be refreshed when the current date time is under a certain threshold (20% before the actual expiration), instead of only after session expiration
Postgrest
- Fix serialization exception occurring when
PostgrestRestException#details
is not a String by @jan-tennert in #956
New Contributors
3.2.0-rc-1
Changes
Changes marked with (new) weren't available in previous pre-releases
All modules
- Don't swallow
CancellationException
by @sproctor in #895 - Only catch serialization exceptions in
bodyOrNull
by @jan-tennert in #904 - Fix simple warnings by @sproctor in #915
- Use Dispatchers.IO by default on multi-threaded platforms by @sproctor in #905
- Configurable default dispatcher
SupabaseClientBuilder#coroutineDispatcher
, defaulting toDispatchers.IO
on supported targets. - Deprecated
AuthConfig#coroutineDispatcher
, replaced by the new client wide dispatcher.
- Configurable default dispatcher
Core
- (new) Add new standard headers by @jan-tennert in #927
Auth
-
(new) Add new event system, add support for error code in OTP links by @jan-tennert in #912
supabase.auth.events.collect { when(it) { is AuthEvent.OtpError -> { println(it.errorCode) } is AuthEvent.RefreshFailure -> TODO() } }
New event system which exists next to the
sessionStatus
, but works independently. Currently there are two events:AuthEvent.OtpError(...)
- will be emitted if an error code was found in a OTP link (deeplink on Android/iOS, URL on JS and Desktop)AuthEvent.RefreshFailure(cause)
- will be emitted if a session refresh failed (regardless if the session is still valid)
This PR also changes the
SessionStatus.RefreshFailure(cause)
:- The
cause
parameter/property is deprecated (use the event for the cause) - This status will only get set, if the session expired.
--> If a refresh failed, an event will always be emitted, but the session status will only get updated if the session also expired. Planning to rename the status in the future to something like
SessionStatus.NeedsRefresh
Additional changes:
- Error related parameters will now be removed from the history when used
-
(new) Deprecate NativeSignInResult.NetworkError as it isn't used by @jan-tennert in #952
-
(new) (JS, WASM JS) Add an option to disable automatic url checking by @jan-tennert in #964
install(Auth) { disableUrlChecking = true //Default: false }
-
Deprecate minimalSettings in favor of minimalConfig by @jan-tennert in #916
-
Fix null result when sign up with Email provider by @hieuwu in #922
-
Add support for providing a custom url launcher by @jan-tennert in #933
You can now provide a customUrlLauncher
for opening URLs in the OAuth flow:install(Auth) { urlLauncher = UrlLauncher { supabase, url -> println("Opening URL: $url") } }
- Fix OAuth server listener resuming coroutine twice by @jan-tennert in #893
A Desktop app using OAuth should no longer produce an exception when exiting the app after usingsignInWith(OAuthProvider)
- Add missing error codes by @jan-tennert in #909:
EmailAddressInvalid
,Web3ProviderDisabled
,Web3UnsupportedChain
- (JS/Wasm JS) Fix exception on non-session hash parameters and only consume used parameters by @jan-tennert in #911
Previously, all URL parameters / hash parameter were removed after successfully authenticating, this is no longer the case. - Fix session expiration check by @jan-tennert in #913
The session will now also be refreshed when the current date time is under a certain threshold (20% before the actual expiration), instead of only after session expiration
Postgrest
- (new) Fix serialization exception occurring when
PostgrestRestException#details
is not a String by @jan-tennert in #956
New Contributors
3.2.0-beta-2
Changes
Auth
- Deprecate minimalSettings in favor of minimalConfig by @jan-tennert in #916
- Fix null result when sign up with Email provider by @hieuwu in #922
- Add support for providing a custom url launcher by @jan-tennert in #933
You can now provide a customUrlLauncher
for opening URLs in the OAuth flow:install(Auth) { urlLauncher = UrlLauncher { supabase, url -> println("Opening URL: $url") } }
3.2.0-beta-1
Changes
Previously wanted to release the version as a whole, but that will take at least to next week. Several features are missing, but there were a few bug fixes!
All modules
- Don't swallow
CancellationException
by @sproctor in #895 - Only catch serialization exceptions in
bodyOrNull
by @jan-tennert in #904 - Fix simple warnings by @sproctor in #915
- Use Dispatchers.IO by default on multi-threaded platforms by @sproctor in #905
- Configurable default dispatcher
SupabaseClientBuilder#coroutineDispatcher
, defaulting toDispatchers.IO
on supported targets. - Deprecated
AuthConfig#coroutineDispatcher
, replaced by the new client wide dispatcher.
- Configurable default dispatcher
Auth
- Fix OAuth server listener resuming coroutine twice by @jan-tennert in #893
A Desktop app using OAuth should no longer produce an exception when exiting the app after usingsignInWith(OAuthProvider)
- Add missing error codes by @jan-tennert in #909:
EmailAddressInvalid
,Web3ProviderDisabled
,Web3UnsupportedChain
- (JS/Wasm JS) Fix exception on non-session hash parameters and only consume used parameters by @jan-tennert in #911
Previously, all URL parameters / hash parameter were removed after successfully authenticating, this is no longer the case. - Fix session expiration check by @jan-tennert in #913
The session will now also be refreshed when the current date time is under a certain threshold (20% before the actual expiration), instead of only after session expiration
New Contributors
3.1.4
Changes
All modules
- Remove
sealed
modifier from interfaces where they are not needed (and prevent mocking in KMP) by @jan-tennert in #883
Core
- Fix custom serializer modules not being used in the
KotlinXSerializer
by @jan-tennert in #881
3.1.3
Changes
Auth
- Fix JS/Wasm hash/code check and removal by @Sparky983 and @jan-tennert in #875
Hashes & PKCE codes should now be correctly checked for on WASM, and removed from the browser history after usage on WASM and JS.
New Contributors
- @Sparky983 made their first contribution in #875
3.1.2
Changes
This version requires Ktor version 3.1.1
or higher.
Core
- Migrate to new crypto dependency by @jan-tennert in 7440814
- Clean up internal
SupabaseClient
code by @jan-tennert in #855 - Migrate to dokka v2 by @jan-tennert in #856
- Update to Ktor version
3.1.1
Compose Auth
- Fix Native Apple Sign In on iOS by @yannickpulver in #866
3.1.1
Changes
Core
- Make
HttpRequestException
a subclass ofIOException
by @jan-tennert in #847
Realtime
- Catch any exceptions when sending a message in realtime by @jan-tennert in #848