mirror of
https://github.com/block/buzz.git
synced 2026-12-01 13:42:45 +00:00
docs(archive): document mixed row-shape invariant on read_archived_events
This commit is contained in:
@@ -77,7 +77,8 @@ const overrides = new Map([
|
||||
// lines. Atomic merge to close the concurrent-seed race. Still queued to split.
|
||||
// IMMEDIATE-tx fix: BEGIN IMMEDIATE replaces DEFERRED unchecked_transaction
|
||||
// in merge_owner_p_kinds comment block (~5 lines). Still queued to split.
|
||||
["src-tauri/src/archive/mod.rs", 1700],
|
||||
// doc-comment: mixed row-shape invariant on read_archived_events (~5 lines).
|
||||
["src-tauri/src/archive/mod.rs", 1705],
|
||||
// archive/store.rs: merge_owner_p_kinds fn (read+union+upsert under a single
|
||||
// SQLite tx) + 4 unit tests (create-when-none, adds-kind, idempotent,
|
||||
// concurrent-interleave). Load-bearing TOCTOU fix for the owner_p shared row.
|
||||
|
||||
@@ -464,6 +464,11 @@ const DEFAULT_READ_LIMIT: i64 = 50;
|
||||
///
|
||||
/// `kinds` is an optional filter; an empty array means "no kinds matched"
|
||||
/// (not "all kinds") — callers should pass `null`/`None` when they want all.
|
||||
///
|
||||
/// Note: stored row payloads are not uniform — kind 44200 rows store the raw
|
||||
/// metric payload JSON, while all other kinds store full Nostr Event JSON. A
|
||||
/// caller doing `Event::from_json` on an unfiltered read must filter by kind
|
||||
/// first (today's only reader filters `kinds: [24200]`).
|
||||
#[tauri::command]
|
||||
pub fn read_archived_events(
|
||||
state: State<'_, AppState>,
|
||||
|
||||
Reference in New Issue
Block a user