dirsql 0.4.115 → 0.4.116

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.
@@ -7,7 +7,8 @@ side.
7
7
 
8
8
  Row events are emitted for **named tables**, so this flow needs a config —
9
9
  [path-tables](../reference/path-tables.md) are scanned per query and are not
10
- watched. Define one next to your files. A named table's columns are whatever
10
+ watched, so `watch()` on an instance with no named tables raises an error and
11
+ `/events` returns `503`. Define one next to your files. A named table's columns are whatever
11
12
  its [`on-file`](../reference/config.md#table) hook emits; here a minimal hook
12
13
  prints each file's basename:
13
14
 
@@ -115,4 +115,4 @@ Row values serialize as in [`POST /query`](#value-serialization).
115
115
  |---|---|
116
116
  | `200` | Stream opened (`text/event-stream`). |
117
117
  | `405` | `POST /events`. Plain-text body `method not allowed`. |
118
- | `503` | The server is in [degraded mode](./cli.md#degraded-mode), or its filesystem watcher failed to start (for example, the inotify limit is exhausted). JSON `{"error": …}` body; for a watcher failure the message starts `filesystem watcher failed to start:` and gives the reason. `POST /query` keeps working. |
118
+ | `503` | The server is in [degraded mode](./cli.md#degraded-mode), or its filesystem watcher failed to start (for example, the inotify limit is exhausted, or the instance has no named tables). JSON `{"error": …}` body; for a watcher failure the message starts `filesystem watcher failed to start:` and gives the reason. `POST /query` keeps working. |
@@ -301,6 +301,10 @@ under the root. The watcher starts on first iteration (Python/TypeScript)
301
301
  or at the `watch()` call (Rust). The stream never terminates on its own;
302
302
  stop consuming it to stop.
303
303
 
304
+ An instance with no named tables cannot be watched: path-tables emit no
305
+ watch events, so `watch()` (and the polling primitives) raise an error naming
306
+ that cause. Define a table first.
307
+
304
308
  Python/TypeScript: each `watch()` call returns an independent stream, and every stream
305
309
  on one instance receives every event observed after it was created, so
306
310
  several consumers (one per client, say) can share one instance.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dirsql",
3
- "version": "0.4.115",
3
+ "version": "0.4.116",
4
4
  "description": "Ephemeral SQL index over a local directory",
5
5
  "license": "MIT",
6
6
  "repository": "https://github.com/thekevinscott/dirsql",
@@ -221,10 +221,10 @@
221
221
  ]
222
222
  },
223
223
  "optionalDependencies": {
224
- "@dirsql/lib-linux-x64-gnu": "0.4.115",
225
- "@dirsql/lib-linux-arm64-gnu": "0.4.115",
226
- "@dirsql/lib-darwin-x64": "0.4.115",
227
- "@dirsql/lib-darwin-arm64": "0.4.115",
228
- "@dirsql/lib-win32-x64-msvc": "0.4.115"
224
+ "@dirsql/lib-linux-x64-gnu": "0.4.116",
225
+ "@dirsql/lib-linux-arm64-gnu": "0.4.116",
226
+ "@dirsql/lib-darwin-x64": "0.4.116",
227
+ "@dirsql/lib-darwin-arm64": "0.4.116",
228
+ "@dirsql/lib-win32-x64-msvc": "0.4.116"
229
229
  }
230
230
  }