@notionhq/custom-blocks 0.3.1 → 0.3.3
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/README.md +2 -8
- package/dist/bridge/SandboxBridge.d.ts +469 -15
- package/dist/bridge/SandboxBridge.d.ts.map +1 -1
- package/dist/bridge/SandboxBridge.js +119 -88
- package/dist/bridge/dataSources/resolveProperty.d.ts +1 -20
- package/dist/bridge/dataSources/resolveProperty.d.ts.map +1 -1
- package/dist/bridge/dataSources/resolveProperty.js +37 -32
- package/dist/bridge/page.d.ts +11 -7
- package/dist/bridge/page.d.ts.map +1 -1
- package/dist/bridge/page.js +20 -50
- package/dist/bridge/sandboxClient.d.ts.map +1 -1
- package/dist/bridge/sandboxClient.js +32 -6
- package/dist/dataSources.d.ts.map +1 -1
- package/dist/dataSources.js +4 -3
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/protocol/dataSources/dateValue.d.ts +2 -2
- package/dist/protocol/dataSources/dateValue.js +9 -7
- package/dist/protocol/messages/createPage.d.ts +64 -2
- package/dist/protocol/messages/createPageResult.d.ts +192 -6
- package/dist/protocol/messages/getPage.d.ts +192 -6
- package/dist/protocol/messages/hostToSandbox.d.ts +704 -22
- package/dist/protocol/messages/queryDataSourceResult.d.ts +128 -4
- package/dist/protocol/messages/sandboxToHost.d.ts +128 -4
- package/dist/protocol/messages/updatePage.d.ts +64 -2
- package/dist/protocol/messages/updatePageResult.d.ts +192 -6
- package/dist/protocol/pages/page.d.ts +360 -12
- package/dist/protocol/pages/page.js +48 -2
- package/dist/protocol/protocolVersion.d.ts +2 -1
- package/dist/protocol/protocolVersion.js +3 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/version.js +1 -1
- package/docs/build-tools.md +55 -0
- package/docs/data-sources.md +12 -9
- package/docs/deployment.md +16 -34
- package/docs/errors.md +65 -52
- package/docs/pages.md +85 -78
- package/package.json +2 -18
- package/src/bridge/SandboxBridge.ts +168 -129
- package/src/bridge/dataSources/resolveProperty.ts +48 -39
- package/src/bridge/page.ts +32 -75
- package/src/bridge/sandboxClient.ts +40 -7
- package/src/dataSources.ts +7 -9
- package/src/index.ts +6 -0
- package/src/types.ts +6 -0
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# Build-tool reference
|
|
2
|
+
|
|
3
|
+
The `@notionhq/custom-blocks/bundle` entrypoint exposes Node.js functions for deployment tools. It
|
|
4
|
+
provides build and upload operations. Worker projects normally use `ntn workers deploy`.
|
|
5
|
+
|
|
6
|
+
The Apps CLI calls `build` and `upload` from `build-blocks` and `upload-blocks`, respectively.
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
import { build, upload } from "@notionhq/custom-blocks/bundle"
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
## Build bundles
|
|
13
|
+
|
|
14
|
+
`build(args: BuildArgs)` returns a `Promise<BuildOutput>`. By default, it imports the worker bundle
|
|
15
|
+
at `dist/index.js` and reads its custom block capabilities. With `manifest`, it reads an Apps SDK
|
|
16
|
+
capability manifest from a JSON file instead. This file contains a `capabilities` array, not the
|
|
17
|
+
block manifest served at `/manifest` during local preview.
|
|
18
|
+
|
|
19
|
+
`BuildArgs` contains these fields:
|
|
20
|
+
|
|
21
|
+
- `out`: Required output directory. Each block's bundle is copied to `<out>/<key>`.
|
|
22
|
+
- `cwd`: Optional project root. Defaults to the process's current directory.
|
|
23
|
+
- `manifest`: Optional path to the Apps SDK capability manifest.
|
|
24
|
+
|
|
25
|
+
Relative `out`, `manifest`, and block source paths resolve from the project root. For a project
|
|
26
|
+
source, `build` installs dependencies, runs the configured build command, and copies its output. For
|
|
27
|
+
a static source, `build` copies the source directory without a build command.
|
|
28
|
+
|
|
29
|
+
`BuildOutput.blocks` is an array of `BuiltBlock` results. Each result contains the block's `key`,
|
|
30
|
+
`bundleDir`, `checksumCrc32`, and `bundleSizeBytes`. The size is the compressed tarball's byte
|
|
31
|
+
length. When the worker or capability manifest declares no custom blocks, `blocks` is empty.
|
|
32
|
+
|
|
33
|
+
The equivalent CLI command is `notion-custom-blocks build --out <dir>`. It accepts `--cwd` and
|
|
34
|
+
`--manifest` with the same path rules. `printBuildOutput` writes a `BuildOutput` as single-line JSON
|
|
35
|
+
between `<__notion_custom_block__>` and `</__notion_custom_block__>`.
|
|
36
|
+
|
|
37
|
+
## Upload bundles
|
|
38
|
+
|
|
39
|
+
`upload(targets: UploadsInput)` returns a `Promise<UploadOutput>`. `UploadsInput` maps block keys to
|
|
40
|
+
`UploadTarget` objects with these fields:
|
|
41
|
+
|
|
42
|
+
- `uploadUrl`: Required presigned upload URL.
|
|
43
|
+
- `bundleDir`: Required path to the bundle directory.
|
|
44
|
+
- `headers`: Optional map of headers supplied with the presigned URL, such as `Content-Length` and
|
|
45
|
+
object tags.
|
|
46
|
+
|
|
47
|
+
`upload` compresses each directory and sends the tarball with an HTTP PUT request. It forwards the
|
|
48
|
+
supplied headers and sets `Content-Type` to `application/gzip` and `x-amz-checksum-crc32` to the
|
|
49
|
+
archive's checksum. Relative `bundleDir` paths resolve from the process's current directory.
|
|
50
|
+
|
|
51
|
+
On success, `UploadOutput.uploaded` maps every uploaded block key to `true`. A failed upload throws
|
|
52
|
+
an error and stops the remaining uploads. Earlier uploads are not rolled back.
|
|
53
|
+
|
|
54
|
+
The equivalent CLI command is `notion-custom-blocks upload --uploads '<json>'`. `parseUploadsInput`
|
|
55
|
+
parses and validates that JSON as `UploadsInput`.
|
package/docs/data-sources.md
CHANGED
|
@@ -388,7 +388,9 @@ await row.updateByKey({
|
|
|
388
388
|
Use `updateByKey` for manifest keys and `updateById` for raw property IDs. The SDK resolves manifest
|
|
389
389
|
keys before sending the request.
|
|
390
390
|
|
|
391
|
-
|
|
391
|
+
Pages returned by `dataSources.getPage`, `dataSources.query`, and `dataSources.create` support
|
|
392
|
+
property writes through `updateByKey`. Pages returned by `pages.get` and `pages.create` support
|
|
393
|
+
property writes through `updateById`.
|
|
392
394
|
|
|
393
395
|
### Archiving and unarchiving a row
|
|
394
396
|
|
|
@@ -533,15 +535,15 @@ refer to the core values inside each property object. For example, “Number”
|
|
|
533
535
|
| `date` | 🟢 Date object | 🟡 Minute precision | 🟢 Supported | 🟢 Supported |
|
|
534
536
|
| `people` | 🟢 User or group references | 🟢 Supported | 🟢 Supported | 🟢 Native name ordering |
|
|
535
537
|
| `files` | 🟡 External files only | 🟡 File URLs only | 🔴 Unavailable | 🔴 Unavailable |
|
|
536
|
-
| `unique_id` |
|
|
538
|
+
| `unique_id` | 🟡 Text fallback | 🔴 Unavailable | 🔴 Unavailable | 🔴 Unavailable |
|
|
537
539
|
| `relation` | 🟢 Page reference array | 🟡 Replaces value. Rejects `has_more: true`. | 🟢 Supported | 🔴 Unavailable for standard relations. ⚫ Notion cannot sort XLDB targets. |
|
|
538
540
|
| `place` | 🟢 Place object | 🟢 Supported | 🔴 Unavailable | 🔴 Unavailable |
|
|
539
|
-
| `formula` |
|
|
540
|
-
| `rollup` |
|
|
541
|
-
| `button` |
|
|
542
|
-
| `verification` |
|
|
541
|
+
| `formula` | 🟡 Text fallback | 🔴 Unavailable | 🔴 Unavailable | 🔴 Unavailable |
|
|
542
|
+
| `rollup` | 🟡 Text fallback | 🔴 Unavailable | 🔴 Unavailable | 🔴 Unavailable for numeric targets or numeric aggregations. ⚫ Notion cannot sort other rollups. |
|
|
543
|
+
| `button` | 🟡 Text fallback | 🔴 Unavailable | ⚫ Not supported in Notion | ⚫ Not supported in Notion |
|
|
544
|
+
| `verification` | 🟡 Text fallback | 🔴 Unavailable | 🔴 Unavailable | 🔴 Unavailable |
|
|
543
545
|
| `last_visited_time` | 🟡 Viewer timestamp or null | 🔴 Unavailable | 🔴 Unavailable | 🔴 Unavailable |
|
|
544
|
-
| `location` |
|
|
546
|
+
| `location` | 🟡 Text fallback | 🔴 Unavailable | 🔴 Unavailable elsewhere. ⚫ Notion disables filters in My Meetings and Library system databases. | 🔴 Unavailable elsewhere. ⚫ Notion disables sorts in Library system databases. |
|
|
545
547
|
| `created_time` | 🟢 Timestamp or null | 🔴 Unavailable | 🔴 Unavailable | 🟡 Schema property only |
|
|
546
548
|
| `last_edited_time` | 🟢 Timestamp or null | 🔴 Unavailable | 🔴 Unavailable | 🟡 Schema property only |
|
|
547
549
|
| `created_by` | 🟢 Actor reference or null | 🔴 Unavailable | 🟡 Schema-backed creator filters | 🟡 Schema property only |
|
|
@@ -677,8 +679,9 @@ if (date?.type === "date" && date.date) {
|
|
|
677
679
|
}
|
|
678
680
|
```
|
|
679
681
|
|
|
680
|
-
`NotionDateInput` describes this date shape for reads and writes
|
|
681
|
-
|
|
682
|
+
`NotionDateInput` describes this date shape for reads and writes, including an optional `reminder`.
|
|
683
|
+
Reminder types are `NotionDateReminder`, `NotionTimeReminder`, `NotionDateTimeReminder`, and
|
|
684
|
+
`NotionDisabledReminder`.
|
|
682
685
|
|
|
683
686
|
## Shared page results
|
|
684
687
|
|
package/docs/deployment.md
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# Deployment and manifests
|
|
2
2
|
|
|
3
|
-
A custom block is a static web bundle
|
|
4
|
-
into a sandboxed `<iframe>`. Custom blocks ship as part of a worker
|
|
5
|
-
data source schema with `worker.customBlock(...)` in the worker's `src/index.ts
|
|
6
|
-
`ntn workers deploy
|
|
3
|
+
A custom block is a static web bundle containing an `index.html` file and optional assets. Notion
|
|
4
|
+
loads the bundle into a sandboxed `<iframe>`. Custom blocks ship as part of a worker. Declare the
|
|
5
|
+
block source and data source schema with `worker.customBlock(...)` in the worker's `src/index.ts`.
|
|
6
|
+
Deploy with `ntn workers deploy`. Notion then serves the built bundle.
|
|
7
7
|
|
|
8
8
|
A custom block manifest describes the data sources a block requires, including their semantic keys,
|
|
9
9
|
display metadata, and property schemas. The block's `worker.customBlock(...)` declaration is the
|
|
@@ -18,13 +18,18 @@ Notion reconciles custom block definitions by their Worker capability keys durin
|
|
|
18
18
|
|
|
19
19
|
## Local development
|
|
20
20
|
|
|
21
|
-
Run `ntn workers customblocks dev` from
|
|
22
|
-
|
|
23
|
-
|
|
21
|
+
Run `ntn workers customblocks dev` from your worker project. The dev shell builds the worker and
|
|
22
|
+
reads its custom block declarations. It serves the shell and blocks on one port, with a separate
|
|
23
|
+
localhost subdomain for each block. Open the shell URL printed by the command. The default port is
|
|
24
|
+
`9873`; the launcher selects another port when needed.
|
|
24
25
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
The dev shell supplies the worker's manifest to the host. When Notion previews a local block
|
|
27
|
+
directly, its host fetches `/manifest` from the block server. In both cases, the host sends the
|
|
28
|
+
manifest to the SDK during initialization.
|
|
29
|
+
|
|
30
|
+
The SDK also attempts a legacy page-relative `manifest` fetch on the exact `localhost` hostname. It
|
|
31
|
+
skips that fetch on block subdomains such as `chart.localhost`. Hosts choose the authoritative
|
|
32
|
+
manifest; blocks do not need to fetch or send one themselves.
|
|
28
33
|
|
|
29
34
|
## Types
|
|
30
35
|
|
|
@@ -33,27 +38,4 @@ this fetch and relies on the host-provided manifest from `init`.
|
|
|
33
38
|
- `ManifestProperty` — a single property declaration inside a `ManifestDataSource`.
|
|
34
39
|
- `ManifestIcon` — the icon variant accepted on a `ManifestDataSource`.
|
|
35
40
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
`notion-custom-blocks build --manifest dist/manifest.json --out <dir>` reads static Apps SDK
|
|
39
|
-
capabilities. Paths in the manifest stay relative to the project root (the current directory, or
|
|
40
|
-
`--cwd`). Without `--manifest`, the command continues to import the Workers SDK bundle at
|
|
41
|
-
`dist/index.js`.
|
|
42
|
-
|
|
43
|
-
Node build tools use one entrypoint:
|
|
44
|
-
|
|
45
|
-
```ts
|
|
46
|
-
import { build, upload } from "@notionhq/custom-blocks/bundle"
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
`build` accepts `BuildArgs` and returns `BuildOutput` containing `BuiltBlock` results. `upload`
|
|
50
|
-
accepts `UploadsInput`, a map of block keys to `UploadTarget`, and returns `UploadOutput`.
|
|
51
|
-
`printBuildOutput` writes the sentinel-wrapped build result; `parseUploadsInput` validates JSON
|
|
52
|
-
upload arguments. The Apps CLI calls these functions from `build-blocks` and `upload-blocks`.
|
|
53
|
-
|
|
54
|
-
Relative `--out` paths also resolve from `--cwd`. Build results include `bundleSizeBytes`, the exact
|
|
55
|
-
compressed tarball length, for size-bound uploads.
|
|
56
|
-
|
|
57
|
-
Upload targets may include a `headers` map containing the headers returned by the server presign,
|
|
58
|
-
including `Content-Length` and object tags. The uploader forwards these alongside the tarball
|
|
59
|
-
checksum and content type.
|
|
41
|
+
For the Node.js build and upload API, see the [build-tool reference](./build-tools.md).
|
package/docs/errors.md
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
# Error handling
|
|
2
2
|
|
|
3
|
-
Pages
|
|
4
|
-
Success returns `{ status: "success",
|
|
5
|
-
`{ status: "error", error }`.
|
|
6
|
-
|
|
7
|
-
Page instance mutations, navigation, and Users methods also retain their result envelopes.
|
|
8
|
-
Initialization still rejects on failure. Hooks and subscriptions keep their existing error behavior.
|
|
3
|
+
Pages, Users, navigation, and asynchronous Data sources methods return a result with a `status`
|
|
4
|
+
field. Success returns `{ status: "success", ... }` with the requested data. Failure returns
|
|
5
|
+
`{ status: "error", error }`. Initialization rejects on failure. Hooks and subscriptions report
|
|
6
|
+
errors separately.
|
|
9
7
|
|
|
10
8
|
## Error format
|
|
11
9
|
|
|
@@ -19,75 +17,90 @@ type CustomBlockErrorInfo<TCode extends string = string> = {
|
|
|
19
17
|
}
|
|
20
18
|
```
|
|
21
19
|
|
|
22
|
-
- `code` is a stable identifier
|
|
23
|
-
- `message` provides
|
|
24
|
-
- `isRetryable` indicates whether
|
|
25
|
-
request or
|
|
26
|
-
|
|
20
|
+
- `code` is a stable identifier for application logic.
|
|
21
|
+
- `message` provides details for developers. Its text can change.
|
|
22
|
+
- `isRetryable` indicates whether the operation could succeed if repeated without changes to the
|
|
23
|
+
request or configuration. A `false` value does not rule out success after you fix the query,
|
|
24
|
+
schema, or bindings.
|
|
27
25
|
|
|
28
|
-
Each API
|
|
29
|
-
|
|
26
|
+
Each API defines known `code` values for autocomplete and accepts other strings. This lets older
|
|
27
|
+
SDKs receive new codes from newer hosts.
|
|
30
28
|
|
|
31
29
|
## API-specific error types
|
|
32
30
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
31
|
+
Each operation has an error code type and an error info type:
|
|
32
|
+
|
|
33
|
+
| Operation | Code type | Info type |
|
|
34
|
+
| ------------------- | ------------------------------------------ | ------------------------------------------ |
|
|
35
|
+
| Create page | `CustomBlockCreatePageErrorCode` | `CustomBlockCreatePageErrorInfo` |
|
|
36
|
+
| Get page | `CustomBlockGetPageErrorCode` | `CustomBlockGetPageErrorInfo` |
|
|
37
|
+
| Open page | `CustomBlockOpenPageErrorCode` | `CustomBlockOpenPageErrorInfo` |
|
|
38
|
+
| Update page | `CustomBlockUpdatePageErrorCode` | `CustomBlockUpdatePageErrorInfo` |
|
|
39
|
+
| Get user | `CustomBlockGetUserErrorCode` | `CustomBlockGetUserErrorInfo` |
|
|
40
|
+
| List users | `CustomBlockListUsersErrorCode` | `CustomBlockListUsersErrorInfo` |
|
|
41
|
+
| Open external URL | `CustomBlockOpenExternalUrlErrorCode` | `CustomBlockOpenExternalUrlErrorInfo` |
|
|
42
|
+
| Query data source | `CustomBlockQueryDataSourceErrorCode` | `CustomBlockQueryDataSourceErrorInfo` |
|
|
43
|
+
| Resolve property | `CustomBlockPropertyErrorCode` | `CustomBlockPropertyErrorInfo` |
|
|
44
|
+
| Resolve data source | `CustomBlockDataSourceResolutionErrorCode` | `CustomBlockDataSourceResolutionErrorInfo` |
|
|
45
|
+
|
|
46
|
+
## Local page update errors
|
|
47
|
+
|
|
48
|
+
The SDK validates all properties before sending an update. These local errors have
|
|
49
|
+
`isRetryable: false`:
|
|
50
|
+
|
|
51
|
+
| Code | Cause |
|
|
52
|
+
| ------------------------ | ------------------------------------------------------------------------------ |
|
|
53
|
+
| `invalid_page_update` | No properties, icon, cover, or archive change. |
|
|
54
|
+
| `invalid_property_value` | Malformed property map or value. |
|
|
55
|
+
| `unmapped_property` | Missing data source context, an invalid or unbound key, or a missing property. |
|
|
56
|
+
| `property_id_mismatch` | A supplied value ID differs from the resolved raw property ID. |
|
|
57
|
+
| `duplicate_property` | Multiple keys resolve to the same raw property ID. |
|
|
43
58
|
|
|
44
59
|
## Data source errors
|
|
45
60
|
|
|
46
|
-
- `data_source_schema_unavailable`:
|
|
47
|
-
|
|
48
|
-
|
|
61
|
+
- `data_source_schema_unavailable`: A query uses filters or sorts, but the host did not provide the
|
|
62
|
+
database schema. Both the SDK and the generic host use this code. Queries without filters or sorts
|
|
63
|
+
can run without a schema.
|
|
49
64
|
- `unmapped_data_source`: The data source has no database binding.
|
|
50
65
|
- `invalid_data_source_query_filter`: The host rejects a filter because its property ID or condition
|
|
51
66
|
does not match the database schema.
|
|
52
67
|
- `invalid_data_source_query_sort`: The host rejects a sort, for example, because its property ID is
|
|
53
68
|
unknown, its property type is unsupported, or the query repeats a sort property.
|
|
54
69
|
|
|
55
|
-
`useDataSource`
|
|
56
|
-
|
|
57
|
-
|
|
70
|
+
On query failure, `useDataSource` sets `error` and `isLoading: false`, keeping the last successful
|
|
71
|
+
rows for that query. A later snapshot clears the error. Framework-neutral subscriptions report
|
|
72
|
+
failures through their optional error callback.
|
|
58
73
|
|
|
59
|
-
|
|
60
|
-
|
|
74
|
+
When the host supplies a changed schema or binding, data source subscriptions repeat the query
|
|
75
|
+
regardless of `isRetryable`.
|
|
61
76
|
|
|
62
77
|
## Initialization errors
|
|
63
78
|
|
|
64
|
-
`initCustomBlock` rejects with `CustomBlockInitializationError`. Its
|
|
65
|
-
`CustomBlockInitializationErrorCode
|
|
66
|
-
|
|
79
|
+
`initCustomBlock` rejects with `CustomBlockInitializationError`. Its
|
|
80
|
+
`CustomBlockInitializationErrorCode` covers handshake failures from the SDK or host, plus local
|
|
81
|
+
iframe errors.
|
|
67
82
|
|
|
68
|
-
`CustomBlockInitializationErrorInfo`
|
|
83
|
+
`CustomBlockInitializationErrorInfo` describes the `{ code, message, isRetryable }` object.
|
|
69
84
|
|
|
70
|
-
|
|
85
|
+
The error code identifies which side failed:
|
|
71
86
|
|
|
72
|
-
- `invalid_connect_payload
|
|
73
|
-
|
|
74
|
-
- `invalid_init_payload
|
|
75
|
-
|
|
76
|
-
- `invalid_init_bindings
|
|
77
|
-
|
|
78
|
-
- `invalid_init_result_payload
|
|
79
|
-
|
|
80
|
-
- `initial_state_timeout
|
|
81
|
-
|
|
82
|
-
- `no_init_result` means that the host did not receive a valid `initResult` before its timeout.
|
|
87
|
+
- `invalid_connect_payload`: The host could not parse the SDK's `connect` message. The host sends
|
|
88
|
+
this code in `init.error` when it can read the `initializationId`.
|
|
89
|
+
- `invalid_init_payload`: The SDK could not parse the host's `init` message. The SDK sends this code
|
|
90
|
+
in `initResult.error` when it can read the expected `initializationId`.
|
|
91
|
+
- `invalid_init_bindings`: The SDK could not apply the data source bindings in the host's valid
|
|
92
|
+
`init` message. The SDK sends this code in `initResult.error`.
|
|
93
|
+
- `invalid_init_result_payload`: The host could not parse the SDK's `initResult`. Only the host
|
|
94
|
+
reports this error.
|
|
95
|
+
- `initial_state_timeout`: The host could not prepare the initial state before its timeout.
|
|
96
|
+
- `no_init_result`: The host did not receive a valid `initResult` before its timeout.
|
|
83
97
|
|
|
84
98
|
See [Lifecycle and initialization](./lifecycle.md) for initialization-specific error codes.
|
|
85
99
|
|
|
86
100
|
## Handling errors
|
|
87
101
|
|
|
88
|
-
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
- Treat `isRetryable` as
|
|
92
|
-
- Use `message` for developer-facing details, not as a stable identifier.
|
|
102
|
+
- Use `code` for error handling and `message` for developer-facing details. Do not branch on
|
|
103
|
+
`message`.
|
|
104
|
+
- Keep a default branch when switching on `code` to handle codes from newer hosts.
|
|
105
|
+
- Treat `isRetryable` as advice when deciding whether to offer or schedule a retry.
|
|
93
106
|
- `"unknown_error"` means the host encountered an unexpected or unclassified failure.
|