debugging
How to debug tursodb using Bytecode comparison, logging, ThreadSanitizer, deterministic simulation, and corruption analysis tools
By tursodatabase · 1,211 installs
npx skills add tursodatabase/turso --skill debugging
Source repository · Upstream listing
Debugging Guide
Bytecode Comparison Flow
Turso aims for SQLite compatibility. When behavior differs:
Example
Manual Query Inspection
Logging
Threading Issues
Use stress tests with ThreadSanitizer:
Deterministic Simulation
Reproduce bugs with seed. Note: simulator uses legacy "limbo" naming.
Architecture Reference
Parser → AST from SQL strings
Code generator → bytecode from AST
Virtual machine → executes SQLite compatible bytecode
Storage layer → B tree operations, paging
Corruption Debugging
For WAL corruption and database integrity issues, use the corruption debug tools in [scripts](./scripts).
See [references/CORRUPTION TOOLS.md](./references/CORRUPTION TOOLS.md) for detailed usage.