@koolbase/js 12.29.0 → 12.31.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +17 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,23 @@ is based on [Keep a Changelog][kac], and this project adheres to
|
|
|
7
7
|
[kac]: https://keepachangelog.com/en/1.1.0/
|
|
8
8
|
[semver]: https://semver.org/
|
|
9
9
|
|
|
10
|
+
## 12.31.0
|
|
11
|
+
|
|
12
|
+
A failed Koolbase request leaves a trace in a development build (#169). Same contract as koolbase_flutter 12.41.0.
|
|
13
|
+
|
|
14
|
+
- **Development log of failed requests**: in a development build (React Native's and Expo's `__DEV__`, else the bundler's `NODE_ENV`), every Koolbase request that fails as the caller receives it prints one `console.warn` line, `[Koolbase] POST /v1/sdk/auth/email/code -> 401 invalid_public_key: ...`: the method, the path, the status and the server's reason. Never the host, the query, a header, the key, a token or the request body. A 401 that renewing the session answers is not printed. A release build, or unbundled code with neither signal, prints nothing.
|
|
15
|
+
- **Covered**: every request through `koolbaseFetch` and `sessionFetch`: auth, data, storage, Functions, analytics, flags and messaging.
|
|
16
|
+
- **Tested**: the line carries the method, path, status and reason and none of the key, token, query, host or body; a success prints nothing; a 401 renewal answers prints nothing; the caller still reads the whole response.
|
|
17
|
+
|
|
18
|
+
## 12.30.0
|
|
19
|
+
|
|
20
|
+
A refused app key is reported as the setup problem it is, never as a wrong password and never by signing the user out (#168, #169). Same contract as koolbase_flutter 12.40.0.
|
|
21
|
+
|
|
22
|
+
- **`KoolbaseInvalidPublicKeyError`** (`invalid_public_key`, 401): the app's Koolbase key is unknown or revoked, or its project is deleted or not ready. The API answers this on any route since #169. It is deliberately not a `KoolbaseUnauthenticatedError`, so it never clears the session.
|
|
23
|
+
- **Behaviour change**: a sign-in call's 401 without a recognised code used to become `InvalidCredentialsError` ("Invalid email or password"), whatever the cause. It is now a generic `KoolbaseAuthError` carrying the server's reason. A refresh's 401 is still a session that expired. The API sends `invalid_credentials` whenever a password is wrong.
|
|
24
|
+
- **Covered surfaces**: auth (with Apple and Google sign-in), data, storage, Functions, fiscal and the offline sync engine.
|
|
25
|
+
- **Tested**: the code maps to its error on each surface; a data 401 for the key does not sign anyone out, and any other data 401 still does.
|
|
26
|
+
|
|
10
27
|
## 12.2.0
|
|
11
28
|
|
|
12
29
|
### Added
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@koolbase/js",
|
|
3
|
-
"version": "12.
|
|
3
|
+
"version": "12.31.0",
|
|
4
4
|
"description": "Koolbase SDK for the browser \u2014 auth, database, storage, realtime, functions, flags and offline sync in one package.",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"types": "./dist/esm/index.d.ts",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"url": "https://github.com/koolbase/koolbase-react-native"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@koolbase/core": "12.
|
|
29
|
+
"@koolbase/core": "12.31.0"
|
|
30
30
|
},
|
|
31
31
|
"publishConfig": {
|
|
32
32
|
"access": "public"
|