Skip to content

docs(examples): query the demo's log with a snapshot, not litelink - #107

Merged
nhobin219 merged 1 commit into
mainfrom
examples-readme-snapshot
Oct 6, 2026
Merged

nhobin219 merged 1 commit into
mainfrom
examples-readme-snapshot

Conversation

@nhobin219

Copy link
Copy Markdown
Owner
  • examples/README.md: the litelink.open(...) snippet that queries the trades demo's log is replaced with Stream.snapshot on streamcast-data/trades.metadata.json. It runs the same sql and scan. A new note says that, while the broker is running, as_of_offset=streamcast.LATEST, broker="ws://127.0.0.1:8765/trades" adds the rows not yet published.
  • README.md: build: 0.14.1 #102 said "a snapshot given broker= reads across both". A snapshot also needs as_of_offset=LATEST to read past the published end, so the sentence now says that.

I ran both against a demo-shaped stream with 6 published rows and 4 unpublished. A plain snapshot returned 6 rows, and LATEST with broker= returned 10. The sql and scan in the snippet returned the expected rows.

🤖 Generated with Claude Code

https://claude.ai/code/session_01FsSDkeb5rVAxA1FSmKKfQi

The examples README opened the trades log with litelink.open. It now
reads the same table through Stream.snapshot on the stream's metadata
file. The main README said a snapshot given broker= reads the buffer
too; it needs as_of_offset=LATEST as well, and now says so.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FsSDkeb5rVAxA1FSmKKfQi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant