@crvouga/mockingbird-service-sqlite 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +170 -0
- package/COMPATIBILITY-AUDIT.md +236 -0
- package/COMPATIBILITY.md +102 -0
- package/LICENSE +21 -0
- package/README.md +405 -0
- package/compat/coverage.json +22231 -0
- package/compat/divergences.json +145 -0
- package/compat/fts-oracle-surface.json +198 -0
- package/compat/requirements.json +20929 -0
- package/compat/scenario-types.ts +63 -0
- package/compat/scenarios.ts +871 -0
- package/compat/smoke-baseline.json +3 -0
- package/compat/sqllogictest-skip.json +5 -0
- package/dist/api/database.d.ts +112 -0
- package/dist/api/snapshot.d.ts +21 -0
- package/dist/api/statement.d.ts +75 -0
- package/dist/ast/nodes.d.ts +476 -0
- package/dist/constraints/check.d.ts +11 -0
- package/dist/errors/index.d.ts +45 -0
- package/dist/executor/attach.d.ts +5 -0
- package/dist/executor/ddl.d.ts +10 -0
- package/dist/executor/dml.d.ts +7 -0
- package/dist/executor/env.d.ts +66 -0
- package/dist/executor/execute.d.ts +4 -0
- package/dist/executor/pragma-engine.d.ts +31 -0
- package/dist/executor/pragma.d.ts +4 -0
- package/dist/executor/result.d.ts +22 -0
- package/dist/executor/select.d.ts +7 -0
- package/dist/executor/simple-select.d.ts +9 -0
- package/dist/executor/triggers.d.ts +11 -0
- package/dist/executor/vtable.d.ts +12 -0
- package/dist/expressions/context.d.ts +30 -0
- package/dist/expressions/equals.d.ts +3 -0
- package/dist/expressions/eval.d.ts +12 -0
- package/dist/expressions/index.d.ts +3 -0
- package/dist/expressions/like.d.ts +16 -0
- package/dist/functions/aggregate.d.ts +8 -0
- package/dist/functions/datetime.d.ts +2 -0
- package/dist/functions/extensions.d.ts +7 -0
- package/dist/functions/index.d.ts +8 -0
- package/dist/functions/json.d.ts +6 -0
- package/dist/functions/math.d.ts +2 -0
- package/dist/functions/pragma-tvf.d.ts +8 -0
- package/dist/functions/registry.d.ts +39 -0
- package/dist/functions/scalar.d.ts +9 -0
- package/dist/functions/table-valued-registry.d.ts +11 -0
- package/dist/functions/table-valued.d.ts +13 -0
- package/dist/functions/window.d.ts +23 -0
- package/dist/index.d.ts +28 -0
- package/dist/index.js +16010 -0
- package/dist/index.js.map +7 -0
- package/dist/indexes/index.d.ts +48 -0
- package/dist/indexes/keys.d.ts +15 -0
- package/dist/json/index.d.ts +7 -0
- package/dist/json/jsonb.d.ts +42 -0
- package/dist/json/ops.d.ts +24 -0
- package/dist/json/parse.d.ts +13 -0
- package/dist/json/path.d.ts +26 -0
- package/dist/json/stringify.d.ts +4 -0
- package/dist/json/tvf.d.ts +13 -0
- package/dist/json/types.d.ts +29 -0
- package/dist/lexer/tokenize.d.ts +23 -0
- package/dist/parser/index.d.ts +17 -0
- package/dist/parser/parser.d.ts +115 -0
- package/dist/planner/access.d.ts +50 -0
- package/dist/planner/index.d.ts +3 -0
- package/dist/runtime/assert.d.ts +11 -0
- package/dist/runtime/catch.d.ts +3 -0
- package/dist/runtime/clock.d.ts +14 -0
- package/dist/runtime/index.d.ts +3 -0
- package/dist/runtime/options.d.ts +25 -0
- package/dist/runtime/prng.d.ts +42 -0
- package/dist/schema/catalog.d.ts +14 -0
- package/dist/schema/master-sql.d.ts +10 -0
- package/dist/serialization/codec.d.ts +19 -0
- package/dist/serialization/index.d.ts +1 -0
- package/dist/serialization/wire.d.ts +61 -0
- package/dist/storage/columnar-slab.d.ts +58 -0
- package/dist/storage/database-state.d.ts +96 -0
- package/dist/storage/index.d.ts +6 -0
- package/dist/storage/row.d.ts +13 -0
- package/dist/storage/table.d.ts +119 -0
- package/dist/transactions/manager.d.ts +19 -0
- package/dist/types/collation.d.ts +4 -0
- package/dist/types/sqlite-atof.d.ts +4 -0
- package/dist/types/sqlite-real-format.d.ts +5 -0
- package/dist/types/strict.d.ts +6 -0
- package/dist/types/value.d.ts +88 -0
- package/dist/unstable.d.ts +20 -0
- package/dist/unstable.js +10343 -0
- package/dist/unstable.js.map +7 -0
- package/dist/vtable/fts/options.d.ts +34 -0
- package/dist/vtable/fts/porter.d.ts +2 -0
- package/dist/vtable/fts/query.d.ts +39 -0
- package/dist/vtable/fts/table.d.ts +78 -0
- package/dist/vtable/fts/tokenize.d.ts +20 -0
- package/dist/vtable/fts5.d.ts +1 -0
- package/dist/vtable/index.d.ts +2 -0
- package/dist/vtable/modules.d.ts +65 -0
- package/package.json +122 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
export type FtsKind = "fts5" | "fts3" | "fts4";
|
|
2
|
+
export type FtsDetail = "full" | "column" | "none";
|
|
3
|
+
export interface FtsColumnDef {
|
|
4
|
+
name: string;
|
|
5
|
+
unindexed: boolean;
|
|
6
|
+
}
|
|
7
|
+
export interface FtsTokenizerConfig {
|
|
8
|
+
/** Primary tokenizer name (unicode61, ascii, porter, trigram). */
|
|
9
|
+
name: string;
|
|
10
|
+
/** Base tokenizer when name is porter. */
|
|
11
|
+
base?: string;
|
|
12
|
+
removeDiacritics?: 0 | 1 | 2;
|
|
13
|
+
tokenchars?: string;
|
|
14
|
+
separators?: string;
|
|
15
|
+
caseSensitive?: boolean;
|
|
16
|
+
removeDiacriticsTrigram?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export interface FtsTableOptions {
|
|
19
|
+
columns: FtsColumnDef[];
|
|
20
|
+
content: "normal" | "contentless" | "external";
|
|
21
|
+
contentTable: string | null;
|
|
22
|
+
contentRowid: string;
|
|
23
|
+
contentlessDelete: boolean;
|
|
24
|
+
prefix: number[];
|
|
25
|
+
columnsize: boolean;
|
|
26
|
+
detail: FtsDetail;
|
|
27
|
+
tokendata: boolean;
|
|
28
|
+
locale: boolean;
|
|
29
|
+
tokenizer: FtsTokenizerConfig;
|
|
30
|
+
/** FTS3/4 */
|
|
31
|
+
languageid: string | null;
|
|
32
|
+
notindexed: Set<string>;
|
|
33
|
+
}
|
|
34
|
+
export declare function parseFtsModuleArgs(moduleArgs: string[], kind: FtsKind): FtsTableOptions;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
export type FtsQueryNode = {
|
|
2
|
+
type: "term";
|
|
3
|
+
value: string;
|
|
4
|
+
prefix: boolean;
|
|
5
|
+
column: string | null;
|
|
6
|
+
columns: string[] | null;
|
|
7
|
+
} | {
|
|
8
|
+
type: "phrase";
|
|
9
|
+
terms: Array<{
|
|
10
|
+
value: string;
|
|
11
|
+
prefix: boolean;
|
|
12
|
+
}>;
|
|
13
|
+
column: string | null;
|
|
14
|
+
columns: string[] | null;
|
|
15
|
+
} | {
|
|
16
|
+
type: "near";
|
|
17
|
+
children: FtsQueryNode[];
|
|
18
|
+
distance: number;
|
|
19
|
+
column: string | null;
|
|
20
|
+
columns: string[] | null;
|
|
21
|
+
} | {
|
|
22
|
+
type: "and";
|
|
23
|
+
children: FtsQueryNode[];
|
|
24
|
+
} | {
|
|
25
|
+
type: "or";
|
|
26
|
+
children: FtsQueryNode[];
|
|
27
|
+
} | {
|
|
28
|
+
type: "not";
|
|
29
|
+
child: FtsQueryNode;
|
|
30
|
+
} | {
|
|
31
|
+
type: "true";
|
|
32
|
+
};
|
|
33
|
+
/**
|
|
34
|
+
* Parse an FTS5 MATCH expression.
|
|
35
|
+
* Implicit AND between adjacent terms; OR binds looser than AND; NOT is binary (a NOT b).
|
|
36
|
+
*/
|
|
37
|
+
export declare function parseFts5Query(input: string): FtsQueryNode;
|
|
38
|
+
/** FTS3/4 query parser (ENABLE_FTS3_PARENTHESIS style). */
|
|
39
|
+
export declare function parseFts3Query(input: string): FtsQueryNode;
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import type { Rowid } from "../../storage/row.js";
|
|
2
|
+
import type { SqlValue } from "../../types/value.js";
|
|
3
|
+
import { type FtsKind, type FtsTableOptions } from "./options.js";
|
|
4
|
+
import { type FtsQueryNode } from "./query.js";
|
|
5
|
+
import { type FtsToken, tokenizeFtsText } from "./tokenize.js";
|
|
6
|
+
export interface Fts5Row {
|
|
7
|
+
rowid: Rowid;
|
|
8
|
+
values: Map<string, SqlValue>;
|
|
9
|
+
/** Per-column tokens with positions. */
|
|
10
|
+
tokensByColumn: Map<string, FtsToken[]>;
|
|
11
|
+
}
|
|
12
|
+
export interface FtsMatchHit {
|
|
13
|
+
column: string;
|
|
14
|
+
position: number;
|
|
15
|
+
startUnit: number;
|
|
16
|
+
endUnit: number;
|
|
17
|
+
term: string;
|
|
18
|
+
}
|
|
19
|
+
export interface FtsMatchCursor {
|
|
20
|
+
tableName: string;
|
|
21
|
+
rowid: Rowid;
|
|
22
|
+
query: string;
|
|
23
|
+
ast: FtsQueryNode;
|
|
24
|
+
hits: FtsMatchHit[];
|
|
25
|
+
/** Phrase term strings used for ranking (flattened). */
|
|
26
|
+
phraseTerms: string[][];
|
|
27
|
+
}
|
|
28
|
+
export declare class Fts5VirtualTable {
|
|
29
|
+
readonly kind: FtsKind;
|
|
30
|
+
readonly name: string;
|
|
31
|
+
readonly columns: string[];
|
|
32
|
+
readonly originalSql: string | null;
|
|
33
|
+
readonly options: FtsTableOptions;
|
|
34
|
+
readonly rows: Map<Rowid, Fts5Row>;
|
|
35
|
+
nextRowid: Rowid;
|
|
36
|
+
private readonly tokenize;
|
|
37
|
+
/** term -> postings */
|
|
38
|
+
private readonly index;
|
|
39
|
+
/** Global doc count for bm25. */
|
|
40
|
+
private docCount;
|
|
41
|
+
/** Average document length (tokens across indexed columns). */
|
|
42
|
+
private avgDocLen;
|
|
43
|
+
private totalTokens;
|
|
44
|
+
constructor(name: string, moduleArgs: string[], originalSql?: string | null, kind?: FtsKind);
|
|
45
|
+
scan(): Fts5Row[];
|
|
46
|
+
insert(values: Map<string, SqlValue>, rowid?: Rowid): Rowid;
|
|
47
|
+
update(rowid: Rowid, updates: Map<string, SqlValue>): void;
|
|
48
|
+
delete(rowid: Rowid): void;
|
|
49
|
+
matches(rowid: Rowid, leftTable: string | null, leftColumn: string, query: string): boolean;
|
|
50
|
+
matchCursor(rowid: Rowid, leftTable: string | null, leftColumn: string, query: string): FtsMatchCursor | null;
|
|
51
|
+
bm25(cursor: FtsMatchCursor, weights?: number[]): number;
|
|
52
|
+
highlight(cursor: FtsMatchCursor, colIndex: number, open: string, close: string): string;
|
|
53
|
+
snippet(cursor: FtsMatchCursor, colIndex: number, open: string, close: string, ellipsis: string, tokenCount: number): string;
|
|
54
|
+
/** FTS3/4 offsets(): "col phrase start length ..." */
|
|
55
|
+
offsets(cursor: FtsMatchCursor): string;
|
|
56
|
+
/** FTS3 matchinfo format encoded as native-style 32-bit little-endian integers. */
|
|
57
|
+
matchinfo(cursor: FtsMatchCursor, format?: string): Uint8Array;
|
|
58
|
+
vocabRows(mode: "row" | "col" | "instance"): Array<Record<string, SqlValue>>;
|
|
59
|
+
clone(): Fts5VirtualTable;
|
|
60
|
+
private detectCommand;
|
|
61
|
+
private runCommand;
|
|
62
|
+
private rebuild;
|
|
63
|
+
private buildRow;
|
|
64
|
+
private indexRow;
|
|
65
|
+
private unindexRow;
|
|
66
|
+
private addPosting;
|
|
67
|
+
private removePosting;
|
|
68
|
+
private indexedColumns;
|
|
69
|
+
private evalNode;
|
|
70
|
+
private normalizeQueryTerm;
|
|
71
|
+
/** For trigram tokenizer, a bare MATCH term is a phrase of overlapping trigrams. */
|
|
72
|
+
private expandTermNode;
|
|
73
|
+
private phraseFreq;
|
|
74
|
+
private phraseDocFreq;
|
|
75
|
+
private docLength;
|
|
76
|
+
private bumpRowid;
|
|
77
|
+
}
|
|
78
|
+
export { tokenizeFtsText };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { FtsTokenizerConfig } from "./options.js";
|
|
2
|
+
export interface FtsToken {
|
|
3
|
+
/** Normalized token text stored in the index. */
|
|
4
|
+
term: string;
|
|
5
|
+
/** Byte offset of the token in the UTF-8 encoding of the source. */
|
|
6
|
+
start: number;
|
|
7
|
+
/** Byte length in UTF-8. */
|
|
8
|
+
length: number;
|
|
9
|
+
/** Token position (0-based) within the column. */
|
|
10
|
+
position: number;
|
|
11
|
+
/** Original end offset in JS string code units (for highlight). */
|
|
12
|
+
startUnit: number;
|
|
13
|
+
endUnit: number;
|
|
14
|
+
}
|
|
15
|
+
export type TokenizerFn = (text: string) => FtsToken[];
|
|
16
|
+
export declare function createTokenizer(config: FtsTokenizerConfig): TokenizerFn;
|
|
17
|
+
export declare function utf8Length(text: string): number;
|
|
18
|
+
export declare function utf8Offset(text: string, unitIndex: number): number;
|
|
19
|
+
/** Legacy helper used by older call sites — simple alphanum split. */
|
|
20
|
+
export declare function tokenizeFtsText(text: string): string[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { type Fts5Row, Fts5VirtualTable, type FtsMatchCursor, tokenizeFtsText } from "./fts/table.js";
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import type { Rowid } from "../storage/row.js";
|
|
2
|
+
import type { SqlValue } from "../types/value.js";
|
|
3
|
+
export interface RTreeRow {
|
|
4
|
+
id: number | bigint;
|
|
5
|
+
coords: number[];
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Simplified R*Tree for SQLite rtree / rtree_i32 modules.
|
|
9
|
+
* Stores axis-aligned boxes; queries filter by bound inequalities in WHERE.
|
|
10
|
+
*/
|
|
11
|
+
export declare class RTreeVirtualTable {
|
|
12
|
+
readonly kind: "rtree";
|
|
13
|
+
readonly name: string;
|
|
14
|
+
readonly columns: string[];
|
|
15
|
+
readonly dimension: number;
|
|
16
|
+
readonly integerCoords: boolean;
|
|
17
|
+
readonly originalSql: string | null;
|
|
18
|
+
readonly rows: Map<string, RTreeRow>;
|
|
19
|
+
/** Shadow node table content for rtreenode/rtreedepth. */
|
|
20
|
+
readonly nodes: Map<number, Uint8Array<ArrayBufferLike>>;
|
|
21
|
+
constructor(name: string, columns: string[], integerCoords?: boolean, originalSql?: string | null);
|
|
22
|
+
scan(): Array<{
|
|
23
|
+
rowid: Rowid;
|
|
24
|
+
values: Map<string, SqlValue>;
|
|
25
|
+
}>;
|
|
26
|
+
insert(values: Map<string, SqlValue>): Rowid;
|
|
27
|
+
update(rowid: Rowid, updates: Map<string, SqlValue>): void;
|
|
28
|
+
delete(rowid: Rowid): void;
|
|
29
|
+
clone(): RTreeVirtualTable;
|
|
30
|
+
}
|
|
31
|
+
export declare class DbStatVirtualTable {
|
|
32
|
+
readonly kind: "dbstat";
|
|
33
|
+
readonly name: string;
|
|
34
|
+
readonly columns: string[];
|
|
35
|
+
readonly originalSql: string | null;
|
|
36
|
+
readonly schemaArg: string | null;
|
|
37
|
+
constructor(name: string, schemaArg?: string | null, originalSql?: string | null);
|
|
38
|
+
clone(): DbStatVirtualTable;
|
|
39
|
+
}
|
|
40
|
+
export declare class BytecodeVirtualTable {
|
|
41
|
+
readonly kind: "bytecode";
|
|
42
|
+
readonly name: string;
|
|
43
|
+
readonly columns: string[];
|
|
44
|
+
readonly originalSql: string | null;
|
|
45
|
+
constructor(name: string, originalSql?: string | null);
|
|
46
|
+
clone(): BytecodeVirtualTable;
|
|
47
|
+
}
|
|
48
|
+
export declare class TablesUsedVirtualTable {
|
|
49
|
+
readonly kind: "tables_used";
|
|
50
|
+
readonly name: string;
|
|
51
|
+
readonly columns: string[];
|
|
52
|
+
readonly originalSql: string | null;
|
|
53
|
+
constructor(name: string, originalSql?: string | null);
|
|
54
|
+
clone(): TablesUsedVirtualTable;
|
|
55
|
+
}
|
|
56
|
+
export declare class FtsVocabVirtualTable {
|
|
57
|
+
readonly kind: "fts5vocab";
|
|
58
|
+
readonly name: string;
|
|
59
|
+
readonly columns: string[];
|
|
60
|
+
readonly ftsTable: string;
|
|
61
|
+
readonly vocabType: string;
|
|
62
|
+
readonly originalSql: string | null;
|
|
63
|
+
constructor(name: string, args: string[], originalSql?: string | null);
|
|
64
|
+
clone(): FtsVocabVirtualTable;
|
|
65
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@crvouga/mockingbird-service-sqlite",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Pure TypeScript in-memory SQLite implementation with zero WASM/native dependencies",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"sideEffects": false,
|
|
8
|
+
"main": "./dist/index.js",
|
|
9
|
+
"module": "./dist/index.js",
|
|
10
|
+
"types": "./dist/index.d.ts",
|
|
11
|
+
"exports": {
|
|
12
|
+
".": {
|
|
13
|
+
"types": "./dist/index.d.ts",
|
|
14
|
+
"import": "./dist/index.js",
|
|
15
|
+
"default": "./dist/index.js"
|
|
16
|
+
},
|
|
17
|
+
"./unstable": {
|
|
18
|
+
"types": "./dist/unstable.d.ts",
|
|
19
|
+
"import": "./dist/unstable.js",
|
|
20
|
+
"default": "./dist/unstable.js"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"files": [
|
|
24
|
+
"dist",
|
|
25
|
+
"AGENTS.md",
|
|
26
|
+
"COMPATIBILITY.md",
|
|
27
|
+
"COMPATIBILITY-AUDIT.md",
|
|
28
|
+
"README.md",
|
|
29
|
+
"LICENSE",
|
|
30
|
+
"compat"
|
|
31
|
+
],
|
|
32
|
+
"repository": {
|
|
33
|
+
"type": "git",
|
|
34
|
+
"url": "git+https://github.com/crvouga/mockingbird.git",
|
|
35
|
+
"directory": "packages/service/sqlite"
|
|
36
|
+
},
|
|
37
|
+
"homepage": "https://github.com/crvouga/mockingbird/tree/main/packages/service/sqlite#readme",
|
|
38
|
+
"bugs": {
|
|
39
|
+
"url": "https://github.com/crvouga/mockingbird/issues"
|
|
40
|
+
},
|
|
41
|
+
"publishConfig": {
|
|
42
|
+
"access": "public",
|
|
43
|
+
"provenance": true
|
|
44
|
+
},
|
|
45
|
+
"scripts": {
|
|
46
|
+
"build": "bun run scripts/build.ts",
|
|
47
|
+
"test": "bun test tests/contract tests/fuzz tests/harness",
|
|
48
|
+
"test:contract": "bun test tests/contract",
|
|
49
|
+
"test:fuzz": "bun test tests/fuzz",
|
|
50
|
+
"test:pbt": "bun test tests/fuzz",
|
|
51
|
+
"test:pbt:random": "bun run scripts/pbt-random.ts",
|
|
52
|
+
"test:fuzz:soak": "SQLITE_MEM_MIXED_STEPS=${SQLITE_MEM_MIXED_STEPS:-48} SQLITE_MEM_STATEFUL_STEPS=${SQLITE_MEM_STATEFUL_STEPS:-48} SQLITE_MEM_WALK_STEPS=${SQLITE_MEM_WALK_STEPS:-48} SQLITE_MEM_FUZZ_RUNS=${SQLITE_MEM_FUZZ_RUNS:-40} bun test tests/fuzz/mixed-stateful.test.ts tests/fuzz/stateful.test.ts tests/fuzz/random-walk.test.ts tests/fuzz/metamorphic tests/fuzz/robustness.test.ts tests/fuzz/sqllogictest.test.ts tests/fuzz/corpus.test.ts",
|
|
53
|
+
"test:metamorphic": "bun test tests/fuzz/metamorphic",
|
|
54
|
+
"test:sqllogictest": "bun test tests/fuzz/sqllogictest.test.ts",
|
|
55
|
+
"test:dst": "bun test tests/fuzz/stateful.test.ts tests/fuzz/mixed-stateful.test.ts tests/fuzz/random-walk.test.ts tests/fuzz/corpus.test.ts",
|
|
56
|
+
"test:walk": "bun test tests/fuzz/random-walk.test.ts",
|
|
57
|
+
"test:walk:soak": "bun run scripts/random-walk.ts",
|
|
58
|
+
"import:sqllogictest": "bun run scripts/import-sqllogictest.ts",
|
|
59
|
+
"example": "bun run --cwd examples/react-vite dev",
|
|
60
|
+
"benchmark": "bun run benchmarks/run.ts --tier default --engine mem",
|
|
61
|
+
"benchmark:bun": "bun run benchmarks/run.ts --tier full --engine both",
|
|
62
|
+
"benchmark:compare": "bun run benchmarks/run.ts --tier default --engine compare --grep compare/ --out benchmarks/results/compare-js.json",
|
|
63
|
+
"benchmark:compare-js": "bun run benchmarks/run.ts --tier default --engine compare-js --grep compare/js/ --out benchmarks/results/compare-js-only.json",
|
|
64
|
+
"benchmark:compare-sqlite": "bun run benchmarks/run.ts --tier default --engine compare-sqlite --grep compare/sqlite/ --out benchmarks/results/compare-sqlite.json",
|
|
65
|
+
"benchmark:ci": "bun run benchmarks/run.ts --tier ci --engine mem --out benchmarks/results/ci-latest.json && bun run benchmarks/compare-ci.ts && bun run benchmarks/check-budgets.ts",
|
|
66
|
+
"benchmark:memory": "bun run benchmarks/check-budgets.ts",
|
|
67
|
+
"benchmark:bundle": "bun run build && bun run benchmarks/bundle.ts",
|
|
68
|
+
"benchmark:report": "bun run benchmarks/report-html.ts",
|
|
69
|
+
"test:browser": "bun run build && bun run scripts/browser-perf.ts",
|
|
70
|
+
"test:browser-sql": "bun run build && bun run scripts/browser-sql-smoke.ts",
|
|
71
|
+
"test:canaries": "bun run scripts/run-canaries.ts",
|
|
72
|
+
"test:sqlite-compat": "bun run scripts/sqlite-compat-gate.ts && bun run scripts/check-skip-register.ts && bun test tests/contract tests/fuzz tests/harness",
|
|
73
|
+
"divergences": "bun run scripts/generate-divergences.ts",
|
|
74
|
+
"fixtures:browser": "bun run scripts/generate-browser-fixtures.ts",
|
|
75
|
+
"inventory": "bun run scripts/sqlite-inventory.ts",
|
|
76
|
+
"scenarios": "bun run scripts/sqlite-scenarios.ts",
|
|
77
|
+
"fts-surface": "bun run scripts/fts-oracle-surface.ts",
|
|
78
|
+
"requirements": "bun run scripts/sqlite-requirements.ts",
|
|
79
|
+
"typecheck": "tsc --noEmit",
|
|
80
|
+
"typecheck:package": "tsc --noEmit -p tsconfig.package.json",
|
|
81
|
+
"format": "biome format --config-path=biome.json --write .",
|
|
82
|
+
"format:check": "biome format --config-path=biome.json .",
|
|
83
|
+
"lint": "biome lint --config-path=biome.json --error-on-warnings .",
|
|
84
|
+
"lint:fix": "biome lint --config-path=biome.json --write --error-on-warnings .",
|
|
85
|
+
"clean": "rm -rf dist",
|
|
86
|
+
"check": "bun run format:check && bun run lint && bun run typecheck && bun run test:sqlite-compat",
|
|
87
|
+
"check:full": "bun run check && bun run build && bun run pack:check && bun run portability",
|
|
88
|
+
"verify-package": "bun run scripts/verify-package.ts",
|
|
89
|
+
"pack:check": "bun ../../../scripts/pack-check.ts",
|
|
90
|
+
"portability": "bun ../../../scripts/portability.ts",
|
|
91
|
+
"example:react-vite": "cd examples/react-vite && bun install && bun run dev",
|
|
92
|
+
"fc": "clear && bun format && bun check:full"
|
|
93
|
+
},
|
|
94
|
+
"devDependencies": {
|
|
95
|
+
"@arethetypeswrong/cli": "^0.18.5",
|
|
96
|
+
"@biomejs/biome": "^2.5.8",
|
|
97
|
+
"@types/bun": "latest",
|
|
98
|
+
"alasql": "^4.17.3",
|
|
99
|
+
"esbuild": "^0.28.2",
|
|
100
|
+
"fast-check": "^4.1.1",
|
|
101
|
+
"publint": "^0.3.23",
|
|
102
|
+
"sql.js": "^1.14.2",
|
|
103
|
+
"typescript": "^5.8.3",
|
|
104
|
+
"wa-sqlite": "^1.0.0"
|
|
105
|
+
},
|
|
106
|
+
"engines": {
|
|
107
|
+
"bun": ">=1.1.0",
|
|
108
|
+
"node": ">=20"
|
|
109
|
+
},
|
|
110
|
+
"keywords": [
|
|
111
|
+
"mockingbird",
|
|
112
|
+
"sqlite",
|
|
113
|
+
"typescript",
|
|
114
|
+
"in-memory",
|
|
115
|
+
"database",
|
|
116
|
+
"sql"
|
|
117
|
+
],
|
|
118
|
+
"mockingbird": {
|
|
119
|
+
"runtime": "portable",
|
|
120
|
+
"layer": "service"
|
|
121
|
+
}
|
|
122
|
+
}
|