@prisma/orm-target-sqlite 8.0.0-rc.25-dev.24 → 8.0.0-rc.25-dev.26
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/dist/{adapter-CxzIV2_z-BBps74Fk.mjs → adapter-CxzIV2_z-DKbo2Ebu.mjs} +7 -7
- package/dist/{adapter-CxzIV2_z-BBps74Fk.mjs.map → adapter-CxzIV2_z-DKbo2Ebu.mjs.map} +1 -1
- package/dist/adapter.mjs +3 -3
- package/dist/adapter__adapter.mjs +1 -1
- package/dist/adapter__control.mjs +4 -4
- package/dist/adapter__runtime.mjs +4 -4
- package/dist/adapter__sql-renderer.mjs +1 -1
- package/dist/{codecs-EhvrdV8v.mjs → codecs-BO3frExA.mjs} +2 -2
- package/dist/{codecs-EhvrdV8v.mjs.map → codecs-BO3frExA.mjs.map} +1 -1
- package/dist/{codecs-CE5McdzP-CZ5F4Trz.mjs → codecs-izq9l1NG-Bb2RnXsx.mjs} +3 -3
- package/dist/{codecs-CE5McdzP-CZ5F4Trz.mjs.map → codecs-izq9l1NG-Bb2RnXsx.mjs.map} +1 -1
- package/dist/{contract-free-CJlg0xGJ.mjs → contract-free-B5S1OSEd.mjs} +2 -2
- package/dist/{contract-free-CJlg0xGJ.mjs.map → contract-free-B5S1OSEd.mjs.map} +1 -1
- package/dist/{data-type-entries-C0WkKiPF-CKPYj4OT.mjs → data-type-entries-DaT4D2GV-DE0V_N6k.mjs} +3 -3
- package/dist/{data-type-entries-C0WkKiPF-CKPYj4OT.mjs.map → data-type-entries-DaT4D2GV-DE0V_N6k.mjs.map} +1 -1
- package/dist/{data-types-C_NKe4Ni-D7r8QkSb.mjs → data-types-Djvapurb-BR-Y4NWN.mjs} +6 -3
- package/dist/data-types-Djvapurb-BR-Y4NWN.mjs.map +1 -0
- package/dist/{date-time-now-generators-DtRz9c2R-BkrBeLl2.mjs → date-time-now-generators-DUb3x91B-D0keGG59.mjs} +3 -3
- package/dist/{date-time-now-generators-DtRz9c2R-BkrBeLl2.mjs.map → date-time-now-generators-DUb3x91B-D0keGG59.mjs.map} +1 -1
- package/dist/{datetime-text-nkVy_w0q-DZnIEmgr.mjs → datetime-text-DPjoF6HJ-se0mLEbc.mjs} +3 -3
- package/dist/{datetime-text-nkVy_w0q-DZnIEmgr.mjs.map → datetime-text-DPjoF6HJ-se0mLEbc.mjs.map} +1 -1
- package/dist/{default-normalizer-Xsys5QJm-bPQiHGKp.mjs → default-normalizer-BANdMVGr-BiUHyBX1.mjs} +3 -3
- package/dist/{default-normalizer-Xsys5QJm-bPQiHGKp.mjs.map → default-normalizer-BANdMVGr-BiUHyBX1.mjs.map} +1 -1
- package/dist/{descriptor-meta-CafFMPhN-Cedi6Vwa.mjs → descriptor-meta-CafFMPhN-x3YQXDSX.mjs} +2 -2
- package/dist/{descriptor-meta-CafFMPhN-Cedi6Vwa.mjs.map → descriptor-meta-CafFMPhN-x3YQXDSX.mjs.map} +1 -1
- package/dist/{descriptor-meta-uVTby90Y-CUfrzHVW.mjs → descriptor-meta-DEr1ALec-DvT6glGq.mjs} +5 -5
- package/dist/{descriptor-meta-uVTby90Y-CUfrzHVW.mjs.map → descriptor-meta-DEr1ALec-DvT6glGq.mjs.map} +1 -1
- package/dist/driver__runtime.mjs +1 -1
- package/dist/{migration-BZoV6EvH.mjs → migration-BYRMZiPU.mjs} +2 -2
- package/dist/{migration-BZoV6EvH.mjs.map → migration-BYRMZiPU.mjs.map} +1 -1
- package/dist/{op-factory-call-2IWWs4es-CajfeAMX.mjs → op-factory-call-DjbjegGT-DsQBI5Ll.mjs} +9 -6
- package/dist/op-factory-call-DjbjegGT-DsQBI5Ll.mjs.map +1 -0
- package/dist/{planner-B3kx0r5b-ByQSd1xn.mjs → planner-C1OMkqV5-BAv-WPw6.mjs} +5 -5
- package/dist/{planner-B3kx0r5b-ByQSd1xn.mjs.map → planner-C1OMkqV5-BAv-WPw6.mjs.map} +1 -1
- package/dist/{planner-produced-sqlite-migration-B_LI7-Li-BjO08-5q.mjs → planner-produced-sqlite-migration-CrbMD1ch-O7Mh_aKY.mjs} +5 -5
- package/dist/{planner-produced-sqlite-migration-B_LI7-Li-BjO08-5q.mjs.map → planner-produced-sqlite-migration-CrbMD1ch-O7Mh_aKY.mjs.map} +1 -1
- package/dist/{render-ops-BdrBMvjY-CyVOYy9i.mjs → render-ops-CQ-Kf4P0-DDUU4OFY.mjs} +3 -3
- package/dist/{render-ops-BdrBMvjY-CyVOYy9i.mjs.map → render-ops-CQ-Kf4P0-DDUU4OFY.mjs.map} +1 -1
- package/dist/{runtime-DQll1Swl.mjs → runtime-C43fN_cJ.mjs} +2 -2
- package/dist/{runtime-DQll1Swl.mjs.map → runtime-C43fN_cJ.mjs.map} +1 -1
- package/dist/{runtime-JuCbuSJz.d.mts → runtime-DqzT70C4.d.mts} +2 -2
- package/dist/{runtime-JuCbuSJz.d.mts.map → runtime-DqzT70C4.d.mts.map} +1 -1
- package/dist/{sqlite-contract-view-6qHjyMcG-BHZ8iO5v.mjs → sqlite-contract-view-c-qO_pKt-DOCoqwrD.mjs} +4 -4
- package/dist/sqlite-contract-view-c-qO_pKt-DOCoqwrD.mjs.map +1 -0
- package/dist/{sqlite-migration-BNMabSfq-C-TEN2jV.mjs → sqlite-migration-Cmzykasm--GxBXXny.mjs} +7 -7
- package/dist/{sqlite-migration-BNMabSfq-C-TEN2jV.mjs.map → sqlite-migration-Cmzykasm--GxBXXny.mjs.map} +1 -1
- package/dist/target.d.mts +1 -1
- package/dist/target.mjs +17 -17
- package/dist/target__codecs.mjs +3 -3
- package/dist/target__contract-free.mjs +1 -1
- package/dist/target__control.mjs +28 -8
- package/dist/target__control.mjs.map +1 -1
- package/dist/target__data-types.mjs +2 -2
- package/dist/target__default-normalizer.mjs +1 -1
- package/dist/target__migration.mjs +2 -2
- package/dist/target__op-factory-call.mjs +1 -1
- package/dist/target__pack.mjs +1 -1
- package/dist/target__planner-produced-sqlite-migration.mjs +1 -1
- package/dist/target__planner.mjs +1 -1
- package/dist/target__render-ops.mjs +1 -1
- package/dist/target__runtime.d.mts +1 -1
- package/dist/target__runtime.mjs +3 -3
- package/package.json +13 -13
- package/dist/data-types-C_NKe4Ni-D7r8QkSb.mjs.map +0 -1
- package/dist/op-factory-call-2IWWs4es-CajfeAMX.mjs.map +0 -1
- package/dist/sqlite-contract-view-6qHjyMcG-BHZ8iO5v.mjs.map +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as SqliteMigration } from "./sqlite-migration-
|
|
3
|
-
import { t as renderOps } from "./render-ops-
|
|
1
|
+
import { f as MIGRATION_MODULE } from "./op-factory-call-DjbjegGT-DsQBI5Ll.mjs";
|
|
2
|
+
import { t as SqliteMigration } from "./sqlite-migration-Cmzykasm--GxBXXny.mjs";
|
|
3
|
+
import { t as renderOps } from "./render-ops-CQ-Kf4P0-DDUU4OFY.mjs";
|
|
4
4
|
import { contractSnapshotJsonSpecifier, contractSnapshotTypesSpecifier } from "@prisma/orm-framework/components/control";
|
|
5
5
|
import { renderImports } from "@prisma/orm-framework/ts-render";
|
|
6
6
|
import { detectScaffoldRuntime, shebangLineFor } from "@prisma/orm-toolchain/migration-tools/migration-ts";
|
|
7
|
-
//#region ../../../3-targets/sqlite/1-target/dist/planner-produced-sqlite-migration-
|
|
7
|
+
//#region ../../../3-targets/sqlite/1-target/dist/planner-produced-sqlite-migration-CrbMD1ch.mjs
|
|
8
8
|
/**
|
|
9
9
|
* Polymorphic TypeScript emitter for the SQLite migration IR. Mirrors the
|
|
10
10
|
* Postgres `render-typescript.ts` — different base-class + factory module
|
|
@@ -137,4 +137,4 @@ var TypeScriptRenderableSqliteMigration = class extends SqliteMigration {
|
|
|
137
137
|
//#endregion
|
|
138
138
|
export { TypeScriptRenderableSqliteMigration as t };
|
|
139
139
|
|
|
140
|
-
//# sourceMappingURL=planner-produced-sqlite-migration-
|
|
140
|
+
//# sourceMappingURL=planner-produced-sqlite-migration-CrbMD1ch-O7Mh_aKY.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"planner-produced-sqlite-migration-
|
|
1
|
+
{"version":3,"file":"planner-produced-sqlite-migration-CrbMD1ch-O7Mh_aKY.mjs","names":["#calls","#meta","#spaceId","#snapshotsImportPath","#destination","#lowerer","#operationsCache"],"sources":["../../../../3-targets/sqlite/1-target/dist/planner-produced-sqlite-migration-CrbMD1ch.mjs"],"sourcesContent":["import { t as SqliteMigration } from \"./sqlite-migration-Cmzykasm.mjs\";\nimport { u as MIGRATION_MODULE } from \"./op-factory-call-DjbjegGT.mjs\";\nimport { t as renderOps } from \"./render-ops-CQ-Kf4P0.mjs\";\nimport { contractSnapshotJsonSpecifier, contractSnapshotTypesSpecifier } from \"@internal/framework-components/control\";\nimport { renderImports } from \"@internal/ts-render\";\nimport { detectScaffoldRuntime, shebangLineFor } from \"@internal/migration-tools/migration-ts\";\n//#region src/core/migrations/render-typescript.ts\n/**\n* Polymorphic TypeScript emitter for the SQLite migration IR. Mirrors the\n* Postgres `render-typescript.ts` — different base-class + factory module\n* specifier, same overall shape.\n*/\nconst BASE_IMPORTS = [{\n\tmoduleSpecifier: MIGRATION_MODULE,\n\tsymbol: \"Migration\"\n}, {\n\tmoduleSpecifier: MIGRATION_MODULE,\n\tsymbol: \"MigrationCLI\"\n}];\nfunction renderCallsToTypeScript(calls, meta) {\n\tconst imports = buildImports(calls, meta);\n\tconst operationsBody = calls.map((c) => c.renderTypeScript()).join(\",\\n\");\n\tconst hasStart = meta.from !== null;\n\tconst startField = hasStart ? [\" override readonly startContractJson = startContract;\"] : [];\n\treturn [\n\t\tshebangLineFor(detectScaffoldRuntime()),\n\t\timports,\n\t\t\"\",\n\t\t`export default class M extends Migration<${hasStart ? \"Start\" : \"never\"}, End> {`,\n\t\t...startField,\n\t\t\" override readonly endContractJson = endContract;\",\n\t\t\"\",\n\t\t\" override get operations() {\",\n\t\t\" return [\",\n\t\tindent(operationsBody, 6),\n\t\t\" ];\",\n\t\t\" }\",\n\t\t\"}\",\n\t\t\"\",\n\t\t\"MigrationCLI.run(import.meta.url, M);\",\n\t\t\"\"\n\t].join(\"\\n\");\n}\nfunction buildImports(calls, meta) {\n\tconst requirements = [...BASE_IMPORTS, ...contractImports(meta)];\n\tfor (const call of calls) for (const req of call.importRequirements()) requirements.push(req);\n\treturn renderImports(requirements.map((requirement) => requirement.moduleSpecifier === \"<migrations.module>\" ? {\n\t\t...requirement,\n\t\tmoduleSpecifier: meta.migrationModule\n\t} : requirement));\n}\n/**\n* The committed contract-JSON imports the scaffold reads its from/to identity\n* from, resolved to the deduplicated snapshot store under\n* `meta.snapshotsImportPath`. The end snapshot is always present; the start\n* snapshot is added only for a non-baseline migration (`meta.from !== null`).\n* The matching `Contract` type imports (aliased `Start`/`End`) feed the\n* `Migration<Start, End>` generics. Baseline emits `Migration<never, End>` with\n* no start imports — `never` is the honest \"no prior contract\" Start.\n*/\nfunction contractImports(meta) {\n\tconst reqs = [{\n\t\tmoduleSpecifier: contractSnapshotJsonSpecifier(meta.snapshotsImportPath, meta.to),\n\t\tsymbol: \"endContract\",\n\t\tkind: \"default\",\n\t\tattributes: { type: \"json\" }\n\t}, {\n\t\tmoduleSpecifier: contractSnapshotTypesSpecifier(meta.snapshotsImportPath, meta.to),\n\t\tsymbol: \"Contract\",\n\t\talias: \"End\",\n\t\ttypeOnly: true\n\t}];\n\tif (meta.from !== null) {\n\t\treqs.push({\n\t\t\tmoduleSpecifier: contractSnapshotJsonSpecifier(meta.snapshotsImportPath, meta.from),\n\t\t\tsymbol: \"startContract\",\n\t\t\tkind: \"default\",\n\t\t\tattributes: { type: \"json\" }\n\t\t});\n\t\treqs.push({\n\t\t\tmoduleSpecifier: contractSnapshotTypesSpecifier(meta.snapshotsImportPath, meta.from),\n\t\t\tsymbol: \"Contract\",\n\t\t\talias: \"Start\",\n\t\t\ttypeOnly: true\n\t\t});\n\t}\n\treturn reqs;\n}\nfunction indent(text, spaces) {\n\tconst pad = \" \".repeat(spaces);\n\treturn text.split(\"\\n\").map((line) => line.trim() ? `${pad}${line}` : line).join(\"\\n\");\n}\n//#endregion\n//#region src/core/migrations/planner-produced-sqlite-migration.ts\nvar TypeScriptRenderableSqliteMigration = class extends SqliteMigration {\n\t#calls;\n\t#meta;\n\t#destination;\n\t#spaceId;\n\t#snapshotsImportPath;\n\t#lowerer;\n\t#operationsCache;\n\tconstructor(calls, meta, spaceId, snapshotsImportPath, destination, lowerer) {\n\t\tsuper();\n\t\tthis.#calls = calls;\n\t\tthis.#meta = meta;\n\t\tthis.#spaceId = spaceId;\n\t\tthis.#snapshotsImportPath = snapshotsImportPath;\n\t\tthis.#destination = destination ?? { storageHash: meta.to };\n\t\tthis.#lowerer = lowerer;\n\t}\n\tget operations() {\n\t\tthis.#operationsCache ??= renderOps(this.#calls, this.#lowerer);\n\t\treturn this.#operationsCache;\n\t}\n\tdescribe() {\n\t\treturn this.#meta;\n\t}\n\tget destination() {\n\t\treturn this.#destination;\n\t}\n\t/**\n\t* Contract space this planner-produced plan applies to. Threaded\n\t* from {@link SqlMigrationPlannerPlanOptions.spaceId} so the runner\n\t* keys the marker row by the right space when executing the plan.\n\t*/\n\tget spaceId() {\n\t\treturn this.#spaceId;\n\t}\n\trenderTypeScript(migrationModule) {\n\t\treturn renderCallsToTypeScript(this.#calls, {\n\t\t\tfrom: this.#meta.from,\n\t\t\tto: this.#meta.to,\n\t\t\tsnapshotsImportPath: this.#snapshotsImportPath,\n\t\t\tmigrationModule\n\t\t});\n\t}\n};\n//#endregion\nexport { TypeScriptRenderableSqliteMigration as t };\n\n//# sourceMappingURL=planner-produced-sqlite-migration-CrbMD1ch.mjs.map"],"mappings":";;;;;;;;;;;;AAYA,MAAM,eAAe,CAAC;CACrB,iBAAiB;CACjB,QAAQ;AACT,GAAG;CACF,iBAAiB;CACjB,QAAQ;AACT,CAAC;AACD,SAAS,wBAAwB,OAAO,MAAM;CAC7C,MAAM,UAAU,aAAa,OAAO,IAAI;CACxC,MAAM,iBAAiB,MAAM,KAAK,MAAM,EAAE,iBAAiB,CAAC,CAAC,CAAC,KAAK,KAAK;CACxE,MAAM,WAAW,KAAK,SAAS;CAC/B,MAAM,aAAa,WAAW,CAAC,wDAAwD,IAAI,CAAC;CAC5F,OAAO;EACN,eAAe,sBAAsB,CAAC;EACtC;EACA;EACA,4CAA4C,WAAW,UAAU,QAAQ;EACzE,GAAG;EACH;EACA;EACA;EACA;EACA,OAAO,gBAAgB,CAAC;EACxB;EACA;EACA;EACA;EACA;EACA;CACD,CAAC,CAAC,KAAK,IAAI;AACZ;AACA,SAAS,aAAa,OAAO,MAAM;CAClC,MAAM,eAAe,CAAC,GAAG,cAAc,GAAG,gBAAgB,IAAI,CAAC;CAC/D,KAAK,MAAM,QAAQ,OAAO,KAAK,MAAM,OAAO,KAAK,mBAAmB,GAAG,aAAa,KAAK,GAAG;CAC5F,OAAO,cAAc,aAAa,KAAK,gBAAgB,YAAY,oBAAoB,wBAAwB;EAC9G,GAAG;EACH,iBAAiB,KAAK;CACvB,IAAI,WAAW,CAAC;AACjB;;;;;;;;;;AAUA,SAAS,gBAAgB,MAAM;CAC9B,MAAM,OAAO,CAAC;EACb,iBAAiB,8BAA8B,KAAK,qBAAqB,KAAK,EAAE;EAChF,QAAQ;EACR,MAAM;EACN,YAAY,EAAE,MAAM,OAAO;CAC5B,GAAG;EACF,iBAAiB,+BAA+B,KAAK,qBAAqB,KAAK,EAAE;EACjF,QAAQ;EACR,OAAO;EACP,UAAU;CACX,CAAC;CACD,IAAI,KAAK,SAAS,MAAM;EACvB,KAAK,KAAK;GACT,iBAAiB,8BAA8B,KAAK,qBAAqB,KAAK,IAAI;GAClF,QAAQ;GACR,MAAM;GACN,YAAY,EAAE,MAAM,OAAO;EAC5B,CAAC;EACD,KAAK,KAAK;GACT,iBAAiB,+BAA+B,KAAK,qBAAqB,KAAK,IAAI;GACnF,QAAQ;GACR,OAAO;GACP,UAAU;EACX,CAAC;CACF;CACA,OAAO;AACR;AACA,SAAS,OAAO,MAAM,QAAQ;CAC7B,MAAM,MAAM,IAAI,OAAO,MAAM;CAC7B,OAAO,KAAK,MAAM,IAAI,CAAC,CAAC,KAAK,SAAS,KAAK,KAAK,IAAI,GAAG,MAAM,SAAS,IAAI,CAAC,CAAC,KAAK,IAAI;AACtF;AAGA,IAAI,sCAAsC,cAAc,gBAAgB;CACvE;CACA;CACA;CACA;CACA;CACA;CACA;CACA,YAAY,OAAO,MAAM,SAAS,qBAAqB,aAAa,SAAS;EAC5E,MAAM;EACN,KAAKA,SAAS;EACd,KAAKC,QAAQ;EACb,KAAKC,WAAW;EAChB,KAAKC,uBAAuB;EAC5B,KAAKC,eAAe,eAAe,EAAE,aAAa,KAAK,GAAG;EAC1D,KAAKC,WAAW;CACjB;CACA,IAAI,aAAa;EAChB,KAAKC,qBAAqB,UAAU,KAAKN,QAAQ,KAAKK,QAAQ;EAC9D,OAAO,KAAKC;CACb;CACA,WAAW;EACV,OAAO,KAAKL;CACb;CACA,IAAI,cAAc;EACjB,OAAO,KAAKG;CACb;;;;;;CAMA,IAAI,UAAU;EACb,OAAO,KAAKF;CACb;CACA,iBAAiB,iBAAiB;EACjC,OAAO,wBAAwB,KAAKF,QAAQ;GAC3C,MAAM,KAAKC,MAAM;GACjB,IAAI,KAAKA,MAAM;GACf,qBAAqB,KAAKE;GAC1B;EACD,CAAC;CACF;AACD"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { l as sqliteError } from "./errors-DxbvEzQp-CeTjoGtL.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { D as isSqliteOpFactoryCall } from "./op-factory-call-DjbjegGT-DsQBI5Ll.mjs";
|
|
3
3
|
import { blindCast } from "@prisma/orm-framework/utils/casts";
|
|
4
4
|
import { isThenable } from "@prisma/orm-framework/utils/promise";
|
|
5
|
-
//#region ../../../3-targets/sqlite/1-target/dist/render-ops-
|
|
5
|
+
//#region ../../../3-targets/sqlite/1-target/dist/render-ops-CQ-Kf4P0.mjs
|
|
6
6
|
function assertSqliteOp(op, callFactoryName) {
|
|
7
7
|
const targetId = blindCast(op).target?.id;
|
|
8
8
|
if (targetId !== "sqlite") throw sqliteError("MIGRATION.TARGET_MISMATCH", `renderOps: expected sqlite op but got target.id="${String(targetId)}" for op.id="${op.id}" (factoryName="${callFactoryName}"). An OpFactoryCall produced an op for a different target on the sqlite planner path; check the call's target binding.`, { meta: {
|
|
@@ -31,4 +31,4 @@ function renderOps(calls, lowerer) {
|
|
|
31
31
|
//#endregion
|
|
32
32
|
export { renderOps as t };
|
|
33
33
|
|
|
34
|
-
//# sourceMappingURL=render-ops-
|
|
34
|
+
//# sourceMappingURL=render-ops-CQ-Kf4P0-DDUU4OFY.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"render-ops-
|
|
1
|
+
{"version":3,"file":"render-ops-CQ-Kf4P0-DDUU4OFY.mjs","names":[],"sources":["../../../../3-targets/sqlite/1-target/dist/render-ops-CQ-Kf4P0.mjs"],"sourcesContent":["import { l as sqliteError } from \"./errors-DxbvEzQp.mjs\";\nimport { b as isSqliteOpFactoryCall } from \"./op-factory-call-DjbjegGT.mjs\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { isThenable } from \"@internal/utils/promise\";\n//#region src/core/migrations/render-ops.ts\nfunction assertSqliteOp(op, callFactoryName) {\n\tconst targetId = blindCast(op).target?.id;\n\tif (targetId !== \"sqlite\") throw sqliteError(\"MIGRATION.TARGET_MISMATCH\", `renderOps: expected sqlite op but got target.id=\"${String(targetId)}\" for op.id=\"${op.id}\" (factoryName=\"${callFactoryName}\"). An OpFactoryCall produced an op for a different target on the sqlite planner path; check the call's target binding.`, { meta: {\n\t\topId: op.id,\n\t\ttargetId: String(targetId),\n\t\tfactoryName: callFactoryName\n\t} });\n}\nfunction checkedOp(opOrPromise, callFactoryName) {\n\tif (isThenable(opOrPromise)) {\n\t\tconst checked = opOrPromise.then((op) => {\n\t\t\tassertSqliteOp(op, callFactoryName);\n\t\t\treturn op;\n\t\t});\n\t\tchecked.catch(() => void 0);\n\t\treturn checked;\n\t}\n\tassertSqliteOp(opOrPromise, callFactoryName);\n\treturn opOrPromise;\n}\nfunction renderOps(calls, lowerer) {\n\treturn calls.flatMap((c) => {\n\t\treturn (isSqliteOpFactoryCall(c) ? c.toOps(lowerer) : [blindCast(c).toOp(lowerer)]).map((opOrPromise) => checkedOp(opOrPromise, c.factoryName));\n\t});\n}\n//#endregion\nexport { renderOps as t };\n\n//# sourceMappingURL=render-ops-CQ-Kf4P0.mjs.map"],"mappings":";;;;;AAKA,SAAS,eAAe,IAAI,iBAAiB;CAC5C,MAAM,WAAW,UAAU,EAAE,CAAC,CAAC,QAAQ;CACvC,IAAI,aAAa,UAAU,MAAM,YAAY,6BAA6B,oDAAoD,OAAO,QAAQ,EAAE,eAAe,GAAG,GAAG,kBAAkB,gBAAgB,0HAA0H,EAAE,MAAM;EACvU,MAAM,GAAG;EACT,UAAU,OAAO,QAAQ;EACzB,aAAa;CACd,EAAE,CAAC;AACJ;AACA,SAAS,UAAU,aAAa,iBAAiB;CAChD,IAAI,WAAW,WAAW,GAAG;EAC5B,MAAM,UAAU,YAAY,MAAM,OAAO;GACxC,eAAe,IAAI,eAAe;GAClC,OAAO;EACR,CAAC;EACD,QAAQ,YAAY,KAAK,CAAC;EAC1B,OAAO;CACR;CACA,eAAe,aAAa,eAAe;CAC3C,OAAO;AACR;AACA,SAAS,UAAU,OAAO,SAAS;CAClC,OAAO,MAAM,SAAS,MAAM;EAC3B,QAAQ,sBAAsB,CAAC,IAAI,EAAE,MAAM,OAAO,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,KAAK,OAAO,CAAC,EAAA,CAAG,KAAK,gBAAgB,UAAU,aAAa,EAAE,WAAW,CAAC;CAC/I,CAAC;AACF"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as sqliteTargetDescriptorMetaRuntime } from "./date-time-now-generators-
|
|
1
|
+
import { n as sqliteTargetDescriptorMetaRuntime } from "./date-time-now-generators-DUb3x91B-D0keGG59.mjs";
|
|
2
2
|
import { structuredError } from "@prisma/orm-framework/utils/structured-error";
|
|
3
3
|
import { type } from "arktype";
|
|
4
4
|
//#region ../../../3-targets/sqlite/1-target/dist/runtime.mjs
|
|
@@ -29,4 +29,4 @@ function validateSqliteIsolationLevel(value) {
|
|
|
29
29
|
//#endregion
|
|
30
30
|
export { validateSqliteIsolationLevel as i, sqliteIsolationLevels as n, sqliteRuntimeTargetDescriptor as r, sqliteIsolationLevelSchema as t };
|
|
31
31
|
|
|
32
|
-
//# sourceMappingURL=runtime-
|
|
32
|
+
//# sourceMappingURL=runtime-C43fN_cJ.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime-
|
|
1
|
+
{"version":3,"file":"runtime-C43fN_cJ.mjs","names":[],"sources":["../../../../3-targets/sqlite/1-target/dist/runtime.mjs"],"sourcesContent":["import { n as sqliteTargetDescriptorMetaRuntime, t as sqliteNowGenerators } from \"./date-time-now-generators-DUb3x91B.mjs\";\nimport { n as SqliteContractSerializer, t as SqliteContractView } from \"./sqlite-contract-view-c-qO_pKt.mjs\";\nimport { structuredError } from \"@internal/utils/structured-error\";\nimport { type } from \"arktype\";\n//#region src/core/runtime/runtime-target.ts\nconst sqliteRuntimeTargetDescriptor = {\n\t...sqliteTargetDescriptorMetaRuntime,\n\tcodecs: () => [],\n\tcreate() {\n\t\treturn {\n\t\t\tfamilyId: \"sql\",\n\t\t\ttargetId: \"sqlite\"\n\t\t};\n\t}\n};\n//#endregion\n//#region src/core/transaction-isolation.ts\nconst sqliteIsolationLevels = { Serializable: \"Serializable\" };\nconst sqliteIsolationLevelSchema = type.enumerated(...Object.values(sqliteIsolationLevels));\nfunction validateSqliteIsolationLevel(value) {\n\tconst result = sqliteIsolationLevelSchema(value);\n\tif (result instanceof type.errors) throw structuredError(\"RUNTIME.ARGUMENT_INVALID\", \"Invalid transaction isolation level\", {\n\t\twhy: result.summary,\n\t\tfix: \"Use Serializable for SQLite transactions.\",\n\t\tmeta: {\n\t\t\targument: \"isolationLevel\",\n\t\t\treceived: value\n\t\t}\n\t});\n\treturn result;\n}\n//#endregion\nexport { SqliteContractSerializer, SqliteContractView, sqliteRuntimeTargetDescriptor as default, sqliteIsolationLevelSchema, sqliteIsolationLevels, sqliteNowGenerators, validateSqliteIsolationLevel };\n\n//# sourceMappingURL=runtime.mjs.map"],"mappings":";;;;AAKA,MAAM,gCAAgC;CACrC,GAAG;CACH,cAAc,CAAC;CACf,SAAS;EACR,OAAO;GACN,UAAU;GACV,UAAU;EACX;CACD;AACD;AAGA,MAAM,wBAAwB,EAAE,cAAc,eAAe;AAC7D,MAAM,6BAA6B,KAAK,WAAW,GAAG,OAAO,OAAO,qBAAqB,CAAC;AAC1F,SAAS,6BAA6B,OAAO;CAC5C,MAAM,SAAS,2BAA2B,KAAK;CAC/C,IAAI,kBAAkB,KAAK,QAAQ,MAAM,gBAAgB,4BAA4B,uCAAuC;EAC3H,KAAK,OAAO;EACZ,KAAK;EACL,MAAM;GACL,UAAU;GACV,UAAU;EACX;CACD,CAAC;CACD,OAAO;AACR"}
|
|
@@ -52,7 +52,7 @@ declare const sqliteRuntimeTargetDescriptor: SqlRuntimeTargetDescriptor<'sqlite'
|
|
|
52
52
|
declare class SqliteContractSerializer extends SqlContractSerializerBase<Contract<SqlStorage>> {
|
|
53
53
|
constructor();
|
|
54
54
|
protected hydrateSqlNamespaceEntry(nsId: string, raw: Record<string, unknown>): Namespace | SqlNamespaceInput;
|
|
55
|
-
|
|
55
|
+
protected printContractV1(contract: Contract<SqlStorage>): JsonObject;
|
|
56
56
|
}
|
|
57
57
|
//#endregion
|
|
58
58
|
//#region src/core/transaction-isolation.d.ts
|
|
@@ -64,4 +64,4 @@ declare const sqliteIsolationLevelSchema: import("arktype/internal/variants/stri
|
|
|
64
64
|
declare function validateSqliteIsolationLevel(value: unknown): SqliteIsolationLevel;
|
|
65
65
|
//#endregion
|
|
66
66
|
export { sqliteIsolationLevels as a, validateSqliteIsolationLevel as c, sqliteIsolationLevelSchema as i, SqliteIsolationLevel as n, sqliteNowGenerators as o, SqliteRuntimeTargetInstance as r, sqliteRuntimeTargetDescriptor as s, SqliteContractSerializer as t };
|
|
67
|
-
//# sourceMappingURL=runtime-
|
|
67
|
+
//# sourceMappingURL=runtime-DqzT70C4.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime-
|
|
1
|
+
{"version":3,"file":"runtime-DqzT70C4.d.mts","names":[],"sources":["../../../../3-targets/sqlite/1-target/dist/runtime.d.mts"],"mappings":";;;;;;;;;;;;iBAWiB,cAAc,SAAS;iBACvB,gBAAgB,SAAS;iBACzB,gBAAgB,SAAS;iBACzB;iBACA;;;;cAIH;WACH;WACA,iBAAiB;;WAEjB;WACA,iBAAiB;;WAEjB;WACA,iBAAiB;;WAEjB;WACA,iBAAiB;;WAEjB;WACA,iBAAiB,UAAU;;WAE3B;WACA,iBAAiB;;;;UAIlB,oCAAoC;cAChC,+BAA+B,qCAAqC;;;;;;;;;cASpE,iCAAiC,0BAA0B,SAAS;EAChF;YACU,yBAAyB,cAAc,KAAK,0BAA0B,YAAY;YAClF,gBAAgB,UAAU,SAAS,cAAc;;;;cAI/C;WACH;;KAEN,+BAA+B,oCAAoC;cAC1D,0EAA0E;iBACvE,6BAA6B,iBAAiB"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { s as sqliteDataTypes } from "./data-types-
|
|
1
|
+
import { s as sqliteDataTypes } from "./data-types-Djvapurb-BR-Y4NWN.mjs";
|
|
2
2
|
import { n as buildSqliteNamespace } from "./sqlite-unbound-database-CfLXSiVo-Dy5VBXGz.mjs";
|
|
3
3
|
import { createDataTypeLookup } from "@prisma/orm-framework/components/codec";
|
|
4
4
|
import { blindCast } from "@prisma/orm-framework/utils/casts";
|
|
5
5
|
import { SqlContractSerializerBase } from "@prisma/orm-family-sql/family/ir";
|
|
6
6
|
import { buildSqlSingleNamespaceView } from "@prisma/orm-family-sql/contract/contract-view";
|
|
7
|
-
//#region ../../../3-targets/sqlite/1-target/dist/sqlite-contract-view-
|
|
7
|
+
//#region ../../../3-targets/sqlite/1-target/dist/sqlite-contract-view-c-qO_pKt.mjs
|
|
8
8
|
/**
|
|
9
9
|
* SQLite target `ContractSerializer` concretion. Mirrors the Postgres
|
|
10
10
|
* shape: inherits the full SQL-family deserialization pipeline and
|
|
@@ -18,7 +18,7 @@ var SqliteContractSerializer = class extends SqlContractSerializerBase {
|
|
|
18
18
|
hydrateSqlNamespaceEntry(nsId, raw) {
|
|
19
19
|
return buildSqliteNamespace(blindCast(super.hydrateSqlNamespaceEntry(nsId, raw)));
|
|
20
20
|
}
|
|
21
|
-
|
|
21
|
+
printContractV1(contract) {
|
|
22
22
|
const { storage, ...rest } = contract;
|
|
23
23
|
const namespacesJson = {};
|
|
24
24
|
for (const [nsId, ns] of Object.entries(storage.namespaces)) namespacesJson[nsId] = {
|
|
@@ -48,4 +48,4 @@ const SqliteContractView = {
|
|
|
48
48
|
//#endregion
|
|
49
49
|
export { SqliteContractView as n, SqliteContractSerializer as t };
|
|
50
50
|
|
|
51
|
-
//# sourceMappingURL=sqlite-contract-view-
|
|
51
|
+
//# sourceMappingURL=sqlite-contract-view-c-qO_pKt-DOCoqwrD.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlite-contract-view-c-qO_pKt-DOCoqwrD.mjs","names":[],"sources":["../../../../3-targets/sqlite/1-target/dist/sqlite-contract-view-c-qO_pKt.mjs"],"sourcesContent":["import { s as sqliteDataTypes } from \"./data-types-Djvapurb.mjs\";\nimport { n as buildSqliteNamespace } from \"./sqlite-unbound-database-CfLXSiVo.mjs\";\nimport { createDataTypeLookup } from \"@internal/framework-components/codec\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { SqlContractSerializerBase } from \"@internal/family-sql/ir\";\nimport { buildSqlSingleNamespaceView } from \"@internal/sql-contract/contract-view\";\n//#region src/core/sqlite-contract-serializer.ts\n/**\n* SQLite target `ContractSerializer` concretion. Mirrors the Postgres\n* shape: inherits the full SQL-family deserialization pipeline and\n* materialises namespace entries as SQLite database concretions that\n* expose `qualifyTable()` for runtime SQL rendering.\n*/\nvar SqliteContractSerializer = class extends SqlContractSerializerBase {\n\tconstructor() {\n\t\tsuper(/* @__PURE__ */ new Map(), [], createDataTypeLookup(sqliteDataTypes));\n\t}\n\thydrateSqlNamespaceEntry(nsId, raw) {\n\t\treturn buildSqliteNamespace(blindCast(super.hydrateSqlNamespaceEntry(nsId, raw)));\n\t}\n\tprintContractV1(contract) {\n\t\tconst { storage, ...rest } = contract;\n\t\tconst namespacesJson = {};\n\t\tfor (const [nsId, ns] of Object.entries(storage.namespaces)) namespacesJson[nsId] = {\n\t\t\tid: ns.id,\n\t\t\tentries: this.serializeNamespaceEntries(ns.entries)\n\t\t};\n\t\treturn blindCast({\n\t\t\t...rest,\n\t\t\tstorage: {\n\t\t\t\tstorageHash: String(storage.storageHash),\n\t\t\t\tnamespaces: namespacesJson,\n\t\t\t\t...storage.types !== void 0 ? { types: this.serializeJsonObject(storage.types) } : {}\n\t\t\t}\n\t\t});\n\t}\n};\n//#endregion\n//#region src/core/sqlite-contract-view.ts\nconst SqliteContractView = {\n\t/** Wrap an already-deserialized SQLite contract in a view. */\n\tfrom(contract) {\n\t\treturn buildSqlSingleNamespaceView(contract);\n\t},\n\t/** Deserialize a SQLite contract JSON envelope and wrap it in a view. */\n\tfromJson(json) {\n\t\treturn buildSqlSingleNamespaceView(new SqliteContractSerializer().deserializeContract(json));\n\t}\n};\n//#endregion\nexport { SqliteContractSerializer as n, SqliteContractView as t };\n\n//# sourceMappingURL=sqlite-contract-view-c-qO_pKt.mjs.map"],"mappings":";;;;;;;;;;;;;AAaA,IAAI,2BAA2B,cAAc,0BAA0B;CACtE,cAAc;EACb,sBAAsB,IAAI,IAAI,GAAG,CAAC,GAAG,qBAAqB,eAAe,CAAC;CAC3E;CACA,yBAAyB,MAAM,KAAK;EACnC,OAAO,qBAAqB,UAAU,MAAM,yBAAyB,MAAM,GAAG,CAAC,CAAC;CACjF;CACA,gBAAgB,UAAU;EACzB,MAAM,EAAE,SAAS,GAAG,SAAS;EAC7B,MAAM,iBAAiB,CAAC;EACxB,KAAK,MAAM,CAAC,MAAM,OAAO,OAAO,QAAQ,QAAQ,UAAU,GAAG,eAAe,QAAQ;GACnF,IAAI,GAAG;GACP,SAAS,KAAK,0BAA0B,GAAG,OAAO;EACnD;EACA,OAAO,UAAU;GAChB,GAAG;GACH,SAAS;IACR,aAAa,OAAO,QAAQ,WAAW;IACvC,YAAY;IACZ,GAAG,QAAQ,UAAU,KAAK,IAAI,EAAE,OAAO,KAAK,oBAAoB,QAAQ,KAAK,EAAE,IAAI,CAAC;GACrF;EACD,CAAC;CACF;AACD;AAGA,MAAM,qBAAqB;;CAE1B,KAAK,UAAU;EACd,OAAO,4BAA4B,QAAQ;CAC5C;;CAEA,SAAS,MAAM;EACd,OAAO,4BAA4B,IAAI,yBAAyB,CAAC,CAAC,oBAAoB,IAAI,CAAC;CAC5F;AACD"}
|
package/dist/{sqlite-migration-BNMabSfq-C-TEN2jV.mjs → sqlite-migration-Cmzykasm--GxBXXny.mjs}
RENAMED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { f as SQLITE_INTEGER_CODEC_ID, h as SQLITE_TEXT_CODEC_ID, t as SQLITE_BIGINT_CODEC_ID } from "./codec-ids-CTshXpbg-tcdbf_VC.mjs";
|
|
2
|
-
import { S as sqliteTime, _ as sqliteInteger, b as sqliteText, c as sqliteDate, h as sqliteDuration, i as sqliteCharacter, o as sqliteCharacterVarying, p as sqliteDecimal, r as sqliteBoolean, t as sqliteBlob, u as sqliteDatetime, v as sqliteJson, y as sqliteReal } from "./data-types-
|
|
2
|
+
import { S as sqliteTime, _ as sqliteInteger, b as sqliteText, c as sqliteDate, h as sqliteDuration, i as sqliteCharacter, o as sqliteCharacterVarying, p as sqliteDecimal, r as sqliteBoolean, t as sqliteBlob, u as sqliteDatetime, v as sqliteJson, y as sqliteReal } from "./data-types-Djvapurb-BR-Y4NWN.mjs";
|
|
3
3
|
import { i as errorSqliteMigrationStackMissing, l as sqliteError } from "./errors-DxbvEzQp-CeTjoGtL.mjs";
|
|
4
|
-
import { n as encodeSqliteDatetime } from "./codecs-
|
|
4
|
+
import { n as encodeSqliteDatetime } from "./codecs-izq9l1NG-Bb2RnXsx.mjs";
|
|
5
5
|
import { n as escapeLiteral } from "./sql-utils-CHBxMmv--Dl7wl7n3.mjs";
|
|
6
|
-
import { n as SqliteContractView } from "./sqlite-contract-view-
|
|
7
|
-
import { n as sqliteResolveDefault } from "./default-normalizer-
|
|
8
|
-
import { A as
|
|
6
|
+
import { n as SqliteContractView } from "./sqlite-contract-view-c-qO_pKt-DOCoqwrD.mjs";
|
|
7
|
+
import { n as sqliteResolveDefault } from "./default-normalizer-BANdMVGr-BiUHyBX1.mjs";
|
|
8
|
+
import { A as sqliteDefaultToDdlColumnDefault, C as buildRecreateSummary, E as indexReplacementCalls, S as buildRecreatePostchecks, _ as RenameColumnCall, a as DataTransformCall, b as ReplaceStoredValueCall, c as DropIndexCall, d as INLINE_AUTOINCREMENT_PRIMARY_KEY, g as RemoveStoredValueCall, h as RemoveStoredKeyCall, i as CreateTableCall, j as sqliteIdentifiersCollide, k as renameTableSteps, l as DropTableCall, m as RecreateTableCall, o as DeleteRowsCall, r as CreateIndexCall, s as DropColumnCall, t as AddColumnCall, u as FillStoredKeyCall, v as RenameStoredKeyCall, y as RenameTableCall } from "./op-factory-call-DjbjegGT-DsQBI5Ll.mjs";
|
|
9
9
|
import { t as CONTROL_TABLE_NAMES } from "./control-tables-D_o8dKRB-n_QqsXcm.mjs";
|
|
10
10
|
import { DdlColumn, ForeignKeyConstraint, PrimaryKeyConstraint, UniqueConstraint } from "@prisma/orm-family-sql/relational-core/ast";
|
|
11
11
|
import { ifDefined } from "@prisma/orm-framework/utils/defined";
|
|
@@ -24,7 +24,7 @@ import { namingOf, namingOfLiveName, parseWireName } from "@prisma/orm-family-sq
|
|
|
24
24
|
import { isArrayEqual } from "@prisma/orm-framework/utils/array-equal";
|
|
25
25
|
import { Migration } from "@prisma/orm-family-sql/family/migration";
|
|
26
26
|
import { MigrationContractViews } from "@prisma/orm-toolchain/migration-tools/migration";
|
|
27
|
-
//#region ../../../3-targets/sqlite/1-target/dist/sqlite-migration-
|
|
27
|
+
//#region ../../../3-targets/sqlite/1-target/dist/sqlite-migration-Cmzykasm.mjs
|
|
28
28
|
/**
|
|
29
29
|
* The SQLite expected-side projection: contract → flat relational schema IR.
|
|
30
30
|
*
|
|
@@ -1360,4 +1360,4 @@ function copyExpressionSlotsOf(copyExpressions, table, option = "copyExpressions
|
|
|
1360
1360
|
//#endregion
|
|
1361
1361
|
export { sqliteSchemaTables as _, createWorkingSchema as a, verifySqliteDatabaseSchema as b, issueNode as c, renameTableByHandStatements as d, renderRenameTableCall as f, sqlitePlannerStrategies as g, sqliteContractToSchema as h, conflictForDisallowedCall as i, pairIndexReplacements as l, sqliteColumnRenameCall as m, buildSqlitePlanDiff as n, diffSqliteSchema as o, sqliteActualSchema as p, coalesceSubtreeIssues as r, indexNameCaseChange as s, SqliteMigration as t, planIssues as u, sqliteTableRenameByHand as v, sqliteTableRenameCall as y };
|
|
1362
1362
|
|
|
1363
|
-
//# sourceMappingURL=sqlite-migration-
|
|
1363
|
+
//# sourceMappingURL=sqlite-migration-Cmzykasm--GxBXXny.mjs.map
|