nebula_db 2.0.4
nebula_db: ^2.0.4 copied to clipboard
A production-grade relational database engine written in pure Dart. Features include WAL, MVCC, B-Tree indexing, SQL execution, and crash recovery.
2.0.4 — 2026-04-29 #
Fixed #
-
Fixed a critical SQL parser crash in
parser.dartcaused by reserved keyword handling in expression context. -
Resolved failure when using column names that match SQL keywords (e.g.
key,value,index,default) inWHEREclauses. -
Fixed crash in authentication/settings flow affecting:
app_settingstable queriesqueryWhere()executionupsert()operations using primary key columns- Application startup settings initialization (
saveSettings,getSettings)
Root Cause #
- SQL lexer marks reserved words (e.g.
key) asTokenType.keyword - Parser previously treated all unexpected keywords as invalid in expression context
- This caused
FormatException: Unexpected token in expression
Changed #
-
Updated
_parsePrimary()insql/parser.dartto correctly handle keyword-based identifiers:- Reserved keywords are now safely promoted to
IdentExprwhen used in expression context
- Reserved keywords are now safely promoted to
-
Maintained strict handling of
PRIMARY KEYparsing via_expectKw('key')to avoid schema conflicts
Improved #
- SQL engine now supports keyword-based column names safely (backward compatible)
- Increased robustness of WHERE clause parsing across all query types
- Prevents future runtime crashes from schema designs using reserved SQL terms
Notes #
- ⚠️ This fix is critical for application stability
- No breaking changes introduced
- Fully backward compatible with existing databases
- Recommended upgrade for all production and desktop/web deployments
2.0.3 — 2026-04-29 #
Added #
-
Added full documentation files for public API coverage:
schema.dart— schema definitions and data types documentationtable_meta.dart— table metadata structure and lifecycledatabase.dart— core database orchestrator documentationsql/module — lexer, parser, planner, and executor documentationstorage/module — pager, WAL, cache, checkpoint, and recovery documentationindex/module — B-Tree v1/v2 and index selection strategy docsconcurrency/module — lock managers and transaction system documentationmvcc/module — MVCC versioning and persistence model docsoptimizer/module — statistics, cost model, and query optimizer documentationrelational/module — relational algebra and join system documentation
-
Added comprehensive Dartdoc comments to public API:
- Achieved >20% documented public API coverage (pub.dev requirement compliance)
- Documented core classes, methods, constructors, and SQL execution flow
-
Added structured API documentation consistency across all modules
Improved #
- Significantly improved pub.dev score compliance (documentation + static analysis)
- Better developer experience with IDE autocomplete and inline docs
- Enhanced readability of internal architecture for contributors
Fixed #
- Fixed missing documentation warnings for critical components:
BTree,BTreeV2Database,Executor,ParserPager,WAL,Cache
- Fixed pub.dev documentation validation failure (>20% requirement now satisfied)
Notes #
- ⚠️ This release is focused on documentation compliance for pub.dev publishing
- No breaking changes introduced
- Recommended upgrade for all users preparing for production or publishing
2.0.2 — 2026-04-29 #
Fixed #
-
Fixed a critical packaging issue where core source files were located outside the
lib/directory, causing import failures when usingpackage:nebula_db/.... -
Resolved multiple "file not found" errors affecting modules such as:
engine/sql/storage/catalog/index/
-
Fixed invalid exports in
nebula_db.dartthat referenced non-existent or unpublished files.
Changed #
-
Reorganized the project structure to comply with Dart package conventions:
- Moved all source files under the
lib/directory
- Moved all source files under the
-
Established a clean public API entry point:
lib/nebula_db.dart
Improved #
-
Full compatibility with:
- Flutter (Windows, Web, Android)
- Dart package resolution system (
pub get,pub.dev)
-
Improved developer experience when integrating the package via
pub.devor local path dependencies
Notes #
- ⚠️ This release fixes a critical packaging issue present in version
2.0.1 - Users are strongly advised to upgrade immediately