@volter/twin-turbopuffer 0.1.0 → 0.1.1

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.
@@ -24,7 +24,7 @@
24
24
  // twin-authored (this build had no account to probe the real service); the statuses follow the
25
25
  // SDK's error classes (400 BadRequest, 401 Authentication, 404 NotFound).
26
26
  import { createHash } from 'node:crypto';
27
- import { applyTwinWriteAtomic, ownFields, twinResources } from '@volter/world-core';
27
+ import { applyTwinWriteAtomic, ownFields, twinResources, worldNow } from '@volter/world-core';
28
28
  import { applyClone, applyWrite, approxLogicalBytes, assertNamespaceName, badRequest, checkConsistency, documentFields, documentSubjectId, loadNamespaces, namespaceFields, queryBilling, queryPerformance, runQuery, schemaWire, SERVICE, TurbopufferError, TURBOPUFFER_RESOURCE_TYPES, vectorEncodingRefusal, } from "./turbopuffer-store.js";
29
29
  const JSON_HEADERS = { 'content-type': 'application/json' };
30
30
  /** Real Turbopuffer routes this twin does not serve yet, each with the manifest gap that tracks it. */
@@ -100,7 +100,7 @@ export async function handleTurbopufferTwinRequest(req) {
100
100
  const [rawPath, rawQuery] = req.path.split('?');
101
101
  const query = new URLSearchParams(rawQuery ?? '');
102
102
  const path = normalizeTurbopufferPath(rawPath ?? '/');
103
- const at = req.occurredAt ?? new Date().toISOString();
103
+ const at = req.occurredAt ?? worldNow();
104
104
  const key = extractTurbopufferApiKey(req.headers);
105
105
  if (key === null)
106
106
  return fail(401, 'missing API key: send Authorization: Bearer <TURBOPUFFER_API_KEY>');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@volter/twin-turbopuffer",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Local Turbopuffer twin: v2 namespaces (write upserts/patches/deletes by id or filter with schema and distance_metric; query with filters, deterministic BM25 incl. last_as_prefix, attribute order, exact ANN and Count/Sum aggregates; multiQuery; deleteAll; metadata; schema; namespace listing) served to the unmodified @turbopuffer/turbopuffer client. Built on @volter/world-core.",
5
5
  "author": "Volter (https://github.com/volter-ai)",
6
6
  "license": "Apache-2.0",
@@ -36,17 +36,17 @@
36
36
  "postpack": "node ../../../scripts/publish/prepare-publish.mjs postpack"
37
37
  },
38
38
  "dependencies": {
39
- "@volter/world-ui": "0.1.0",
39
+ "@volter/world-ui": "0.1.1",
40
40
  "react": "^19.2.7",
41
41
  "react-dom": "^19.2.7"
42
42
  },
43
43
  "peerDependencies": {
44
- "@volter/world-core": "2.0.0"
44
+ "@volter/world-core": "2.0.1"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@types/bun": "^1.2.20",
48
48
  "@types/node": "^24.0.0",
49
- "@volter/world-core": "2.0.0",
49
+ "@volter/world-core": "2.0.1",
50
50
  "@volter/world-tooling": "0.1.0",
51
51
  "typescript": "^5.9.0"
52
52
  },
@@ -24,7 +24,7 @@
24
24
  // twin-authored (this build had no account to probe the real service); the statuses follow the
25
25
  // SDK's error classes (400 BadRequest, 401 Authentication, 404 NotFound).
26
26
  import { createHash } from 'node:crypto';
27
- import { applyTwinWriteAtomic, ownFields, twinResources, type TwinWriteInput } from '@volter/world-core';
27
+ import { applyTwinWriteAtomic, ownFields, twinResources, type TwinWriteInput, worldNow } from '@volter/world-core';
28
28
  import {
29
29
  applyClone,
30
30
  applyWrite,
@@ -130,7 +130,7 @@ export async function handleTurbopufferTwinRequest(req: TurbopufferTwinRequest):
130
130
  const [rawPath, rawQuery] = req.path.split('?');
131
131
  const query = new URLSearchParams(rawQuery ?? '');
132
132
  const path = normalizeTurbopufferPath(rawPath ?? '/');
133
- const at = req.occurredAt ?? new Date().toISOString();
133
+ const at = req.occurredAt ?? worldNow();
134
134
 
135
135
  const key = extractTurbopufferApiKey(req.headers);
136
136
  if (key === null) return fail(401, 'missing API key: send Authorization: Bearer <TURBOPUFFER_API_KEY>');