Skip to content

v0.8.0

Choose a tag to compare

@github-actions github-actions released this 16 Nov 15:22
· 133 commits to main since this release

TinyStore 0.8.0

What's new, with code in every language: https://tinyshed.org/tinystore/docs/releases/v0.8.0

bun add @tinyshed/tinystore@0.8.0
npm install @tinyshed/tinystore@0.8.0
pip install tinyshed-tinystore==0.8.0

Built for linux-x64, linux-arm64, linux-x64-musl, linux-arm64-musl, darwin-arm64, darwin-x64, win32-x64. Each archive holds the
tinystore executable in bin/, and in lib/ the core's library and the Node addon; the Go
SDK fetches its platform's at the first open. SHA256SUMS checks them all.

Changes since v0.7.1

Changed names

  • locks: fail invalid, in rust, bun and node, python and go, a semaphore opened again in the program with another limit than its first open gave, naming both, where each open counted its holders to its own limit
  • wire: let a read token open and read only what the store holds, as it is, a file it lacks not_found and a name invalid, and make or bind nothing

Features

  • sql: apply a migration named .draft.sql after a copy of the database, refuse one edited since, and take the database back to the copy and apply it again with tinystore migrate --redo-drafts
  • search: keep on each hit what each half gave it, textScore and similarity, and a minSimilarity floor that keeps a far vector out of the sum, in rust, bun, python and go

Fixes

  • blobs: keep the bytes a database's transaction put when its commit's outcome is unknown, where a row that committed named bytes it had removed
  • sql: fail a read invalid where a column's declared type in a file another program wrote is not UTF-8, which panicked out of the call
  • sql: refuse a statement whose text holds a NUL as invalid, in a read, a write, a batch, a transaction and a migration, where SQLite ran only what came before it and said nothing
  • sqlite: answer every write beside a submitted write whose completion panics and lead its file's queue on, said once in the log, where they waited for good
  • cli: show a stored line in tinystore logs and events list as the console shows it, its further lines and a value's of several below it, indented, each other control character as its escape, and another program's colours only where the command paints its own, reset after them
  • store: fail invalid at once a close from inside a handler it waits for, a worker's, a schedule's or a subscription's, rather than wait out the handler's timeout for itself and close the files under it
  • sql: count no parenthesis inside quotes or a comment, as rust does, where the bun, python and go builders ask whether a condition is one group, which left an or of two groups bare beside an and
  • backup: refuse on windows, before it writes anything, the restore of a backup that holds a file named as windows names a device, as a database nul made elsewhere, which windows before 11 wrote into the device
  • config: ignore a change of a live map another program kept whose values hold a secret in this program's type, which changed that secret while it ran
  • records: cut a page several windows fill, and write its next, by each event's time to the nanosecond, so that on windows the next page no longer reads again events stored less than 100 ns apart
  • mcp: keep answering when a write to stdout takes nothing, which under node on windows stopped a server's answers and left its host waiting
  • cli: end a connection whose answers can no longer be written at once, where a private child stayed up and its parent waited until it next sent something
  • cli: keep a private child answering when a write to its stdout pipe takes nothing, which under node on windows ended its answers part way
  • kv: refuse a value whose Some holds nothing, Some(()) or Some(None), which read back as None
  • kv: refuse a key written with a ttl of zero, which wrote a key already gone and answered that it was written
  • jobs: walk on past a job whose value no longer reads, all giving it as an error that names it by its id or its number and time
  • jobs: drop the steps a job kept for its old value when an update changes it while it waits for a retry, so that its next attempt does not answer with them
  • jobs: return at once from a worker's or a schedule's stop called by one of its own handlers, rather than wait out the timeout for itself
  • jobs,kv: refuse a repeat, a rate or a timeout longer than the years a job keeps, and stop a backoff, a rate and a quota's window from overflowing on the largest numbers
  • kv: write no renewal of an idle key that expired before the renewal was written, so that a key read absent stays absent
  • jobs: fill a page of jobs in one state, reading on past the others a window at a time, so that no page but the last is empty or short
  • jobs: fail a run whose retry or snooze names a time outside the years 1 to 9999, and refuse such an answer over the wire, so that no job reads as parked and runs early
  • blobs: scrub past a file the disk will not read, marking it damaged, and pass over one another program holds until the next pass
  • backup: end a backup sent over the wire cancelled once its client has given no credit for a minute, rather than hold a worker and a copy of the store for ever
  • backup: refuse a backup limit before it copies when its snapshot would leave the disk less free than the store keeps, rather than fill the disk
  • backup: keep a directory whose restore's process died from opening, its RESTORING marker written first and removed last, and say to restore it again
  • backup: restore a backup whose manifest passes 64 MiB, reading it as it comes, bounded by the files its zip holds, and write it without spaces
  • backup: remove at a store's open the snapshot a backup whose process died left in its directory, keeping one a backup still running holds
  • wire: refuse a ttl or a time on kv.take and kv.delete, and match a read's ETag without its quotes and in either case, as the core does
  • jobs: give back uncounted the job an awaited claim leased when its future is dropped before it answers, rather than leave it leased to nobody for the queue's timeout
  • blobs: give no file the content id of bytes a rollback could not remove, so that maintenance no longer removes the next file's bytes with them
  • console: stop a message, an event's name, a value under its line or a source from writing escape sequences, carriage returns or forged lines to the terminal on a pretty line, in rust, bun, python and go
  • cli: say outcome unknown for a job or an event without an id whose answer was lost, where the command and mcp sent it again and wrote it twice
  • wire: answer a transaction's call that does not decode invalid naming its field and keep the transaction, where it rolled back saying the client left
  • wire: keep the calls a transaction queues while it waits for the writer within its stream's credit, given back once each is answered rather than as it is read
  • store: refuse and close an engine that opens while its store closes, which stayed open with a handle that wrote on
  • sql: refuse a text of two statements as invalid, saying a batch runs several, where it was internal
  • records: give the events of one append that carry no time a time 100 ns apart each, so that more than a page of them reads, a page at a time
  • search: take a row SQLite removed for a replace out of its table's index once a search meets it, and fill that search's page past it
  • sql: refuse a new database named as windows names a device, con, nul or com1, on every platform so that a store's directory moves there, and open one a store already holds
  • sql: end a query's piece that ends in a -- comment with a newline, so that it hides no condition, order or where the builder writes after it, and refuse one that ends inside a /* comment, in rust, bun, python and go
  • sql: refuse a limit or an offset before list, which paged through every row, and in every sdk the steps an update or a delete would drop, as the rust core does
  • search: answer corrupt rather than panic when a damaged search.db holds a key's postings out of their order or clusters with no centroid
  • search: answer corrupt rather than panic when a piece's directory places a block past its run, in a merge, a purge or a filtered search
  • mcp: refuse a sql_query of more than 200 rows rather than answer the first 200 as though they were all
  • config: stop printing a toml file's line, a .env file's line and an Env's variables in a config's errors and Debug, which showed the secrets on them
  • config: stop quoting what a layer gave a map, a list or any value in a config's errors, which printed a secret inside it
  • sqlite: fail alone and invalid a write that leaves a deferred foreign key broken, rather than fail every write of its commit outcome_unknown, and fail invalid a transaction that does
  • sqlite: stop a blocking write that took an awaited write's lead from failing internal and leaving every later write of its file waiting when the writes before it fill a commit, and answer closed where a close took it
  • metrics: read a page on past the series without a sample in its range, and take nothing of a block or a head whose samples its window falls between, so a read's page with a next holds a sample rather than none
  • metrics: read an aggregate's page on past the groups without a sample in its range, and count no bucket for a sample past its end, so a page with a next answers a bucket rather than none
  • jobs: list the jobs added without an id too, after those with ids, so a queue of plain jobs no longer reads as empty

Full history: v0.7.1...v0.8.0.