@prisma/orm-family-sql 8.0.0-rc.19-dev.1 → 8.0.0-rc.19-dev.2
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/{ast-DlajRqlB.d.mts → ast-BySjcUKx.d.mts} +3 -3
- package/dist/{ast-DlajRqlB.d.mts.map → ast-BySjcUKx.d.mts.map} +1 -1
- package/dist/{attribute-specs-cHzMPvMl.d.mts → attribute-specs-BsaemIyu.d.mts} +9 -11
- package/dist/attribute-specs-BsaemIyu.d.mts.map +1 -0
- package/dist/{authoring-entity-types-DUQLeBf_-nuhFC6jJ.d.mts → authoring-entity-types-DUQLeBf_-DSWWvkLJ.d.mts} +2 -2
- package/dist/{authoring-entity-types-DUQLeBf_-nuhFC6jJ.d.mts.map → authoring-entity-types-DUQLeBf_-DSWWvkLJ.d.mts.map} +1 -1
- package/dist/builder.d.mts +3 -3
- package/dist/builder__runtime.d.mts +10 -10
- package/dist/builder__runtime.mjs +1 -1
- package/dist/builder__types.d.mts +5 -5
- package/dist/{codec-descriptor-registry-4kw8FPpo.mjs → codec-descriptor-registry-MG2bFxW_.mjs} +5 -14
- package/dist/codec-descriptor-registry-MG2bFxW_.mjs.map +1 -0
- package/dist/collection-methods-BTknGdHI.d.mts +1 -0
- package/dist/{collection-methods-BtJYB_5s-0fek2_wK.d.mts → collection-methods-D2UnCS0S-CRYoAOtB.d.mts} +5 -5
- package/dist/{collection-methods-BtJYB_5s-0fek2_wK.d.mts.map → collection-methods-D2UnCS0S-CRYoAOtB.d.mts.map} +1 -1
- package/dist/{config-types-DY37pCIx.mjs → config-types-BLDwd9wS.mjs} +2 -2
- package/dist/{config-types-DY37pCIx.mjs.map → config-types-BLDwd9wS.mjs.map} +1 -1
- package/dist/{config-types-DN0IueHY.d.mts → config-types-D8quwydu.d.mts} +4 -4
- package/dist/{config-types-DN0IueHY.d.mts.map → config-types-D8quwydu.d.mts.map} +1 -1
- package/dist/{contract-builder-DT689tII.mjs → contract-builder-CNeGxqP_.mjs} +96 -99
- package/dist/contract-builder-CNeGxqP_.mjs.map +1 -0
- package/dist/{contract-builder-DZSUqbp0.d.mts → contract-builder-xFftVmD8.d.mts} +85 -69
- package/dist/contract-builder-xFftVmD8.d.mts.map +1 -0
- package/dist/contract-emitter.mjs +1 -1
- package/dist/contract-prisma7__provider.d.mts +2 -2
- package/dist/contract-prisma7__provider.mjs +4 -4
- package/dist/contract-psl.d.mts +4 -4
- package/dist/contract-psl.d.mts.map +1 -1
- package/dist/contract-psl.mjs +1 -1
- package/dist/contract-psl__attribute-specs.d.mts +1 -1
- package/dist/contract-psl__attribute-specs.mjs +1 -1
- package/dist/contract-psl__provider.d.mts +2 -2
- package/dist/contract-psl__provider.mjs +2 -2
- package/dist/contract-psl__provider.mjs.map +1 -1
- package/dist/contract-ts.d.mts +3 -3
- package/dist/contract-ts.mjs +3 -3
- package/dist/contract-ts__config-types.d.mts +1 -1
- package/dist/contract-ts__config-types.mjs +1 -1
- package/dist/contract-ts__contract-builder.d.mts +2 -2
- package/dist/contract-ts__contract-builder.mjs +2 -2
- package/dist/{contract-view-BAbRgQMW.d.mts → contract-view-BgpEwVz0.d.mts} +2 -2
- package/dist/{contract-view-BAbRgQMW.d.mts.map → contract-view-BgpEwVz0.d.mts.map} +1 -1
- package/dist/contract.d.mts +13 -13
- package/dist/contract.mjs +7 -7
- package/dist/contract__contract-view.d.mts +1 -1
- package/dist/contract__data-type.d.mts +1 -1
- package/dist/contract__entity-kinds.d.mts +1 -1
- package/dist/contract__entity-kinds.mjs +1 -1
- package/dist/contract__factories.d.mts +1 -1
- package/dist/contract__factories.mjs +1 -1
- package/dist/contract__foreign-key-materialization.d.mts +1 -1
- package/dist/contract__index-type-validation.d.mts +1 -1
- package/dist/contract__resolve-storage-table.d.mts +1 -1
- package/dist/contract__types.d.mts +5 -5
- package/dist/contract__types.mjs +4 -4
- package/dist/contract__validators.d.mts +1 -1
- package/dist/contract__validators.mjs +2 -2
- package/dist/{control-CF-KJYTH.mjs → control-KwF_dWdr.mjs} +33 -67
- package/dist/control-KwF_dWdr.mjs.map +1 -0
- package/dist/{control-adapter-Bn0uhplA-BBax-2PG.d.mts → control-adapter-Bn0uhplA-D0fhkvnJ.d.mts} +8 -8
- package/dist/{control-adapter-Bn0uhplA-BBax-2PG.d.mts.map → control-adapter-Bn0uhplA-D0fhkvnJ.d.mts.map} +1 -1
- package/dist/{control-adapter-QzlyTp1z.d.mts → control-adapter-El4czoUh.d.mts} +4 -4
- package/dist/{control-adapter-QzlyTp1z.d.mts.map → control-adapter-El4czoUh.d.mts.map} +1 -1
- package/dist/{control-YFLg-7Gn.d.mts → control-cq1XZ1wo.d.mts} +24 -24
- package/dist/control-cq1XZ1wo.d.mts.map +1 -0
- package/dist/{data-type-BacIoCfv.d.mts → data-type-CWFhlpaq.d.mts} +3 -3
- package/dist/{data-type-BacIoCfv.d.mts.map → data-type-CWFhlpaq.d.mts.map} +1 -1
- package/dist/{db-BmrN9nRS-DGNx3jwd.d.mts → db-BmrN9nRS-MT5cfCJy.d.mts} +13 -13
- package/dist/{db-BmrN9nRS-DGNx3jwd.d.mts.map → db-BmrN9nRS-MT5cfCJy.d.mts.map} +1 -1
- package/dist/{ddl-types-BBrLVtS--u4u-I8L5.d.mts → ddl-types-By5mT2_S--j4lTxme.d.mts} +4 -4
- package/dist/{ddl-types-BBrLVtS--u4u-I8L5.d.mts.map → ddl-types-By5mT2_S--j4lTxme.d.mts.map} +1 -1
- package/dist/{derived-checks-DpPkO6Dt-D-vp9vY3.d.mts → derived-checks-DpPkO6Dt-D6tfanWv.d.mts} +3 -3
- package/dist/{derived-checks-DpPkO6Dt-D-vp9vY3.d.mts.map → derived-checks-DpPkO6Dt-D6tfanWv.d.mts.map} +1 -1
- package/dist/{derived-checks-CXW9ytkb-B_zxX1-8.mjs → derived-checks-iXF3y0Ki-28vqz_8w.mjs} +22 -18
- package/dist/derived-checks-iXF3y0Ki-28vqz_8w.mjs.map +1 -0
- package/dist/{diff-CzUyZmJi.d.mts → diff-Cqz45svW.d.mts} +7 -7
- package/dist/{diff-CzUyZmJi.d.mts.map → diff-Cqz45svW.d.mts.map} +1 -1
- package/dist/diff-DZ82XaGR.mjs.map +1 -1
- package/dist/{dist-Bxu8hzMC.mjs → dist-D8RKUdwh.mjs} +4 -5
- package/dist/dist-D8RKUdwh.mjs.map +1 -0
- package/dist/{entity-kinds-CQ_jwgYv-DoOBWwvX.mjs → entity-kinds-JR5SAm5h-ZkDejOUK.mjs} +4 -8
- package/dist/entity-kinds-JR5SAm5h-ZkDejOUK.mjs.map +1 -0
- package/dist/{entity-kinds-BCMNbwxO.d.mts → entity-kinds-OhCjfrIe.d.mts} +2 -2
- package/dist/{entity-kinds-BCMNbwxO.d.mts.map → entity-kinds-OhCjfrIe.d.mts.map} +1 -1
- package/dist/{exports-D3JbXqm_-mm-wWICO.mjs → exports-CRROThzp-BNz0pGj0.mjs} +8 -65
- package/dist/{exports-D3JbXqm_-mm-wWICO.mjs.map → exports-CRROThzp-BNz0pGj0.mjs.map} +1 -1
- package/dist/{expression-CC4544Y8-C_EWTA_0.d.mts → expression-6ld_ZQL6-CQghHqQ4.d.mts} +8 -8
- package/dist/{expression-CC4544Y8-C_EWTA_0.d.mts.map → expression-6ld_ZQL6-CQghHqQ4.d.mts.map} +1 -1
- package/dist/expression-BLiObOS8.d.mts +2 -0
- package/dist/{expression-BdaU48Qq-Dff96hT_.d.mts → expression-CieaNuRM-BpwVyjJL.d.mts} +4 -4
- package/dist/expression-CieaNuRM-BpwVyjJL.d.mts.map +1 -0
- package/dist/{factories-DkD3nMYt.mjs → factories-C4JbtO84.mjs} +2 -2
- package/dist/{factories-DkD3nMYt.mjs.map → factories-C4JbtO84.mjs.map} +1 -1
- package/dist/{factories-B4AMRt6O.d.mts → factories-CfHDga-q.d.mts} +3 -3
- package/dist/{factories-B4AMRt6O.d.mts.map → factories-CfHDga-q.d.mts.map} +1 -1
- package/dist/family.d.mts +14 -14
- package/dist/family.mjs +6 -6
- package/dist/family__control-adapter.d.mts +2 -2
- package/dist/family__control.d.mts +4 -4
- package/dist/family__control.mjs +3 -3
- package/dist/family__diff.d.mts +1 -1
- package/dist/family__diff.mjs +1 -1
- package/dist/family__ir.d.mts +1 -1
- package/dist/family__ir.mjs +1 -1
- package/dist/family__migration.d.mts +1 -1
- package/dist/family__pack.d.mts +1 -1
- package/dist/family__pack.mjs +2 -2
- package/dist/family__psl-build.d.mts +1 -1
- package/dist/family__psl-infer.d.mts +1 -1
- package/dist/family__runtime.d.mts +2 -2
- package/dist/{foreign-key-materialization-bL-t2oPB.d.mts → foreign-key-materialization-CgW18KP-.d.mts} +3 -3
- package/dist/{foreign-key-materialization-bL-t2oPB.d.mts.map → foreign-key-materialization-CgW18KP-.d.mts.map} +1 -1
- package/dist/{functions-wFi6AtCc.d.mts → functions-DTInIMZT.d.mts} +6 -6
- package/dist/{functions-wFi6AtCc.d.mts.map → functions-DTInIMZT.d.mts.map} +1 -1
- package/dist/{generator-functions-DuDZSQHE-BbKhsXck.mjs → generator-functions-DuDZSQHE-Dl5EP61A.mjs} +2 -2
- package/dist/{generator-functions-DuDZSQHE-BbKhsXck.mjs.map → generator-functions-DuDZSQHE-Dl5EP61A.mjs.map} +1 -1
- package/dist/{index-v5QXXCrA.d.mts → index-3aEIvk82.d.mts} +22 -22
- package/dist/{index-v5QXXCrA.d.mts.map → index-3aEIvk82.d.mts.map} +1 -1
- package/dist/{index-BRFLss5v.d.mts → index-ffCr9ySU.d.mts} +3 -3
- package/dist/{index-BRFLss5v.d.mts.map → index-ffCr9ySU.d.mts.map} +1 -1
- package/dist/{index-reference-DSsn39tX-EEkv1N4w.d.mts → index-reference-4wsdeB7v-DiTLLldN.d.mts} +4 -4
- package/dist/{index-reference-DSsn39tX-EEkv1N4w.d.mts.map → index-reference-4wsdeB7v-DiTLLldN.d.mts.map} +1 -1
- package/dist/index-reference-Da9mdOjD.d.mts +1 -0
- package/dist/{index-type-validation-Cz2T3FJn.d.mts → index-type-validation-Ibtp3RKo.d.mts} +3 -3
- package/dist/{index-type-validation-Cz2T3FJn.d.mts.map → index-type-validation-Ibtp3RKo.d.mts.map} +1 -1
- package/dist/{interpreter-DTwRm0sl-DHX1SdeJ.mjs → interpreter-BGgim2OE-D9BG-4aU.mjs} +148 -130
- package/dist/interpreter-BGgim2OE-D9BG-4aU.mjs.map +1 -0
- package/dist/{ir-qK4wX3D3.d.mts → ir-BjC1VOuq.d.mts} +3 -3
- package/dist/{ir-qK4wX3D3.d.mts.map → ir-BjC1VOuq.d.mts.map} +1 -1
- package/dist/{middleware-C7H9kh01-l6_mYpN2.d.mts → middleware-DHkW6pRr-CFiQojK4.d.mts} +3 -3
- package/dist/{middleware-C7H9kh01-l6_mYpN2.d.mts.map → middleware-DHkW6pRr-CFiQojK4.d.mts.map} +1 -1
- package/dist/middleware-GO31SJSv.d.mts +1 -0
- package/dist/{migration-tfMTDejH.d.mts → migration-DeekERBF.d.mts} +4 -4
- package/dist/{migration-tfMTDejH.d.mts.map → migration-DeekERBF.d.mts.map} +1 -1
- package/dist/operations.d.mts +1 -1
- package/dist/orm-client.d.mts +21 -21
- package/dist/orm-client.mjs +2 -2
- package/dist/{pack-NM8AYiUp.mjs → pack-B5_CfdgT.mjs} +3 -3
- package/dist/{pack-NM8AYiUp.mjs.map → pack-B5_CfdgT.mjs.map} +1 -1
- package/dist/{pack-AyeYizq-.d.mts → pack-BJ53Inwa.d.mts} +6 -6
- package/dist/{pack-AyeYizq-.d.mts.map → pack-BJ53Inwa.d.mts.map} +1 -1
- package/dist/{plan-BiCLdXQr-0ZB4P6b9.d.mts → plan-Cr4azjnG-lIrzIrmu.d.mts} +5 -5
- package/dist/plan-Cr4azjnG-lIrzIrmu.d.mts.map +1 -0
- package/dist/plan-OXQ8s6Ee.d.mts +2 -0
- package/dist/psl-build-D5VG40ej.mjs.map +1 -1
- package/dist/{psl-build-C4ia2uM6.d.mts → psl-build-prdUw3sC.d.mts} +4 -4
- package/dist/{psl-build-C4ia2uM6.d.mts.map → psl-build-prdUw3sC.d.mts.map} +1 -1
- package/dist/{psl-column-resolution-BgThghdu-BWaFlWYV.d.mts → psl-column-resolution-ChZqioOc-DcjGSXDp.d.mts} +3 -4
- package/dist/psl-column-resolution-ChZqioOc-DcjGSXDp.d.mts.map +1 -0
- package/dist/{psl-field-resolution-DpGsATq3-BREG9FbU.mjs → psl-field-resolution-C9zwpsAu-DCc7Eifv.mjs} +163 -133
- package/dist/psl-field-resolution-C9zwpsAu-DCc7Eifv.mjs.map +1 -0
- package/dist/{psl-infer-B_n-rSCj.d.mts → psl-infer-CpTRaF5I.d.mts} +3 -3
- package/dist/{psl-infer-B_n-rSCj.d.mts.map → psl-infer-CpTRaF5I.d.mts.map} +1 -1
- package/dist/{query-lane-context-DEr9NHM--ClIM8v5T.d.mts → query-lane-context-BCEoKy0_-DQOOliDn.d.mts} +11 -20
- package/dist/query-lane-context-BCEoKy0_-DQOOliDn.d.mts.map +1 -0
- package/dist/query-lane-context-BssPNZey.d.mts +1 -0
- package/dist/relational-core.d.mts +13 -13
- package/dist/relational-core__aggregate-descriptor-registry.d.mts +1 -1
- package/dist/relational-core__ast.d.mts +3 -3
- package/dist/relational-core__codec-descriptor-registry.d.mts +6 -7
- package/dist/relational-core__codec-descriptor-registry.d.mts.map +1 -1
- package/dist/relational-core__codec-descriptor-registry.mjs +1 -1
- package/dist/relational-core__collection-methods.d.mts +2 -2
- package/dist/relational-core__contract-free.d.mts +3 -3
- package/dist/relational-core__expression.d.mts +3 -3
- package/dist/relational-core__functions.d.mts +1 -1
- package/dist/relational-core__index-reference.d.mts +2 -2
- package/dist/relational-core__middleware.d.mts +2 -2
- package/dist/relational-core__plan.d.mts +3 -3
- package/dist/relational-core__query-lane-context.d.mts +3 -3
- package/dist/relational-core__types.d.mts +2 -2
- package/dist/{resolve-storage-table-8N2xelSh.d.mts → resolve-storage-table-CxmU_MPu.d.mts} +3 -3
- package/dist/{resolve-storage-table-8N2xelSh.d.mts.map → resolve-storage-table-CxmU_MPu.d.mts.map} +1 -1
- package/dist/{runtime-BlUQqGCH.d.mts → runtime-Bmndf-fm.d.mts} +2 -2
- package/dist/{runtime-BlUQqGCH.d.mts.map → runtime-Bmndf-fm.d.mts.map} +1 -1
- package/dist/runtime.d.mts +5 -5
- package/dist/runtime.mjs +1 -1
- package/dist/runtime__internal__prepared-query.d.mts +1 -1
- package/dist/{schema-differ-DmP74bB8-BfEQ_9cY.d.mts → schema-differ-DmP74bB8-0ZupRJKb.d.mts} +5 -5
- package/dist/{schema-differ-DmP74bB8-BfEQ_9cY.d.mts.map → schema-differ-DmP74bB8-0ZupRJKb.d.mts.map} +1 -1
- package/dist/schema-ir.d.mts +1 -1
- package/dist/schema-ir__types.d.mts +2 -2
- package/dist/{schema-verify-BwRdzbHb-DfFAS0EC.mjs → schema-verify-C3wbdviw-BifQBCpu.mjs} +3 -3
- package/dist/{schema-verify-BwRdzbHb-DfFAS0EC.mjs.map → schema-verify-C3wbdviw-BifQBCpu.mjs.map} +1 -1
- package/dist/{serialized-index-52COq1yV-CUJ2F65u.mjs → serialized-index-DjCCnXB1-C_YccpTL.mjs} +3 -3
- package/dist/{serialized-index-52COq1yV-CUJ2F65u.mjs.map → serialized-index-DjCCnXB1-C_YccpTL.mjs.map} +1 -1
- package/dist/{sql-contract-serializer-sMY3prTx-CpZa5Nlt.mjs → sql-contract-serializer-sMY3prTx-BkFoHhST.mjs} +4 -4
- package/dist/{sql-contract-serializer-sMY3prTx-CpZa5Nlt.mjs.map → sql-contract-serializer-sMY3prTx-BkFoHhST.mjs.map} +1 -1
- package/dist/{sql-execution-plan-BEhLlwYP-seGNP8Qr.d.mts → sql-execution-plan-3uxYjHyu-C0Z4_RSY.d.mts} +3 -3
- package/dist/sql-execution-plan-3uxYjHyu-C0Z4_RSY.d.mts.map +1 -0
- package/dist/{sql-storage-tZhB8nS5-8NSWT0TW.d.mts → sql-storage-DeCAh5Hi-nJQUIgfL.d.mts} +6 -9
- package/dist/sql-storage-DeCAh5Hi-nJQUIgfL.d.mts.map +1 -0
- package/dist/{storage-table-DC9afJhr-CmRU56OS.d.mts → storage-table-Bf1ZjnxO-NvkG2pgq.d.mts} +2 -8
- package/dist/storage-table-Bf1ZjnxO-NvkG2pgq.d.mts.map +1 -0
- package/dist/{storage-table-DN36E2yE-0ncS821l.mjs → storage-table-DDvN83mw-CbCFr5wm.mjs} +2 -3
- package/dist/{storage-table-DN36E2yE-0ncS821l.mjs.map → storage-table-DDvN83mw-CbCFr5wm.mjs.map} +1 -1
- package/dist/{transaction-state-DR3nKTmH-2-ewbth1.d.mts → transaction-state-DR3nKTmH-D6VdY7YX.d.mts} +9 -9
- package/dist/{transaction-state-DR3nKTmH-2-ewbth1.d.mts.map → transaction-state-DR3nKTmH-D6VdY7YX.d.mts.map} +1 -1
- package/dist/types-BUggiEEH.d.mts +1 -0
- package/dist/{types-M_FeBD9w.mjs → types-C7610W2l.mjs} +5 -6
- package/dist/types-C7610W2l.mjs.map +1 -0
- package/dist/{types-CI5lled6-CDV4aYNB.d.mts → types-CI5lled6-DMWq8aOX.d.mts} +9 -9
- package/dist/{types-CI5lled6-CDV4aYNB.d.mts.map → types-CI5lled6-DMWq8aOX.d.mts.map} +1 -1
- package/dist/{types-B2Dee96w.d.mts → types-CRbj_WQf.d.mts} +7 -12
- package/dist/types-CRbj_WQf.d.mts.map +1 -0
- package/dist/{types-DiD6BqoN-ZF53hwPp.d.mts → types-CuCxAQat-BBGUHEku.d.mts} +3 -4
- package/dist/types-CuCxAQat-BBGUHEku.d.mts.map +1 -0
- package/dist/types-DDqbg3WC.d.mts +1 -0
- package/dist/{types-Dqf87mfA-BOElvimQ.d.mts → types-DfKvtJwS-tndgHh53.d.mts} +4 -4
- package/dist/{types-Dqf87mfA-BOElvimQ.d.mts.map → types-DfKvtJwS-tndgHh53.d.mts.map} +1 -1
- package/dist/{types-GgcOrYm_-RhoxnXdj.d.mts → types-DriMIMNQ-BBacSgaI.d.mts} +4 -5
- package/dist/types-DriMIMNQ-BBacSgaI.d.mts.map +1 -0
- package/dist/{types-Dy1w8GHm-7hJTBOLL.d.mts → types-TXO7x1BA-DuW4v0rw.d.mts} +11 -11
- package/dist/{types-Dy1w8GHm-7hJTBOLL.d.mts.map → types-TXO7x1BA-DuW4v0rw.d.mts.map} +1 -1
- package/dist/{validators-CTZ-hU2l.d.mts → validators-BDuMio1F.d.mts} +3 -4
- package/dist/validators-BDuMio1F.d.mts.map +1 -0
- package/dist/{validators-Cfy0jmZ2.mjs → validators-xXKEHvnw.mjs} +25 -12
- package/dist/validators-xXKEHvnw.mjs.map +1 -0
- package/package.json +18 -18
- package/dist/attribute-specs-cHzMPvMl.d.mts.map +0 -1
- package/dist/codec-descriptor-registry-4kw8FPpo.mjs.map +0 -1
- package/dist/collection-methods-CwBVxvll.d.mts +0 -1
- package/dist/contract-builder-DT689tII.mjs.map +0 -1
- package/dist/contract-builder-DZSUqbp0.d.mts.map +0 -1
- package/dist/control-CF-KJYTH.mjs.map +0 -1
- package/dist/control-YFLg-7Gn.d.mts.map +0 -1
- package/dist/derived-checks-CXW9ytkb-B_zxX1-8.mjs.map +0 -1
- package/dist/dist-Bxu8hzMC.mjs.map +0 -1
- package/dist/entity-kinds-CQ_jwgYv-DoOBWwvX.mjs.map +0 -1
- package/dist/expression-BdaU48Qq-Dff96hT_.d.mts.map +0 -1
- package/dist/expression-DI_LoyKf.d.mts +0 -2
- package/dist/index-reference-burEIuXy.d.mts +0 -1
- package/dist/interpreter-DTwRm0sl-DHX1SdeJ.mjs.map +0 -1
- package/dist/middleware-CpxZxPGp.d.mts +0 -1
- package/dist/plan-BiCLdXQr-0ZB4P6b9.d.mts.map +0 -1
- package/dist/plan-xPa9B6I3.d.mts +0 -2
- package/dist/psl-column-resolution-BgThghdu-BWaFlWYV.d.mts.map +0 -1
- package/dist/psl-field-resolution-DpGsATq3-BREG9FbU.mjs.map +0 -1
- package/dist/query-lane-context--sVodqqM.d.mts +0 -1
- package/dist/query-lane-context-DEr9NHM--ClIM8v5T.d.mts.map +0 -1
- package/dist/sql-execution-plan-BEhLlwYP-seGNP8Qr.d.mts.map +0 -1
- package/dist/sql-storage-tZhB8nS5-8NSWT0TW.d.mts.map +0 -1
- package/dist/storage-table-DC9afJhr-CmRU56OS.d.mts.map +0 -1
- package/dist/types-B2Dee96w.d.mts.map +0 -1
- package/dist/types-BQC-To7K.d.mts +0 -1
- package/dist/types-D_nlUp-1.d.mts +0 -1
- package/dist/types-DiD6BqoN-ZF53hwPp.d.mts.map +0 -1
- package/dist/types-GgcOrYm_-RhoxnXdj.d.mts.map +0 -1
- package/dist/types-M_FeBD9w.mjs.map +0 -1
- package/dist/validators-CTZ-hU2l.d.mts.map +0 -1
- package/dist/validators-Cfy0jmZ2.mjs.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as TraitExpression, D as isExpression, E as createRawSql, O as param, S as StorageColumnScopeField, T as codecOf, _ as RawSqlStatementBuilder, a as CodecValue, b as ScalarListExpression, c as RawAffectedCountQuery, d as RawRow, f as RawRowQuery, g as RawSqlInterpolation, h as RawSqlBuilder, i as CodecTypesBase, k as toExpr, l as RawCodecInferer, m as RawRowSpecEntry, n as BuildOperationSpec, o as Expression, p as RawRowSpec, r as CodecExpression, s as NoReservedRowColumn, t as AffectedCount, u as RawPlanContext, v as RawSqlStatementTag, w as buildOperation, x as ScopeField, y as RawSqlTag } from "./expression-
|
|
2
|
-
import { t as ExpressionImpl } from "./expression-
|
|
3
|
-
import "./expression-
|
|
1
|
+
import { C as TraitExpression, D as isExpression, E as createRawSql, O as param, S as StorageColumnScopeField, T as codecOf, _ as RawSqlStatementBuilder, a as CodecValue, b as ScalarListExpression, c as RawAffectedCountQuery, d as RawRow, f as RawRowQuery, g as RawSqlInterpolation, h as RawSqlBuilder, i as CodecTypesBase, k as toExpr, l as RawCodecInferer, m as RawRowSpecEntry, n as BuildOperationSpec, o as Expression, p as RawRowSpec, r as CodecExpression, s as NoReservedRowColumn, t as AffectedCount, u as RawPlanContext, v as RawSqlStatementTag, w as buildOperation, x as ScopeField, y as RawSqlTag } from "./expression-6ld_ZQL6-CQghHqQ4.mjs";
|
|
2
|
+
import { t as ExpressionImpl } from "./expression-CieaNuRM-BpwVyjJL.mjs";
|
|
3
|
+
import "./expression-BLiObOS8.mjs";
|
|
4
4
|
export { AffectedCount, BuildOperationSpec, CodecExpression, CodecTypesBase, CodecValue, Expression, ExpressionImpl, NoReservedRowColumn, RawAffectedCountQuery, RawCodecInferer, RawPlanContext, RawRow, RawRowQuery, RawRowSpec, RawRowSpecEntry, RawSqlBuilder, RawSqlInterpolation, RawSqlStatementBuilder, RawSqlStatementTag, RawSqlTag, ScalarListExpression, ScopeField, StorageColumnScopeField, TraitExpression, buildOperation, codecOf, createRawSql, isExpression, param, toExpr };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as Subquery, i as FunctionsContext, n as BuiltinFunctions, o as SubqueryMarker, r as Functions, s as createFunctions, t as BooleanCodecType } from "./functions-
|
|
1
|
+
import { a as Subquery, i as FunctionsContext, n as BuiltinFunctions, o as SubqueryMarker, r as Functions, s as createFunctions, t as BooleanCodecType } from "./functions-DTInIMZT.mjs";
|
|
2
2
|
export { type BooleanCodecType, type BuiltinFunctions, type Functions, type FunctionsContext, type Subquery, type SubqueryMarker, createFunctions };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as createIndexReferences, i as UniqueIndexNamesOfType, n as IndexReferencesInput, o as uniqueIndexNamesOfType, r as TableIndexReferences, t as IndexReference } from "./index-reference-
|
|
2
|
-
import "./index-reference-
|
|
1
|
+
import { a as createIndexReferences, i as UniqueIndexNamesOfType, n as IndexReferencesInput, o as uniqueIndexNamesOfType, r as TableIndexReferences, t as IndexReference } from "./index-reference-4wsdeB7v-DiTLLldN.mjs";
|
|
2
|
+
import "./index-reference-Da9mdOjD.mjs";
|
|
3
3
|
export { type IndexReference, type IndexReferencesInput, type TableIndexReferences, type UniqueIndexNamesOfType, createIndexReferences, uniqueIndexNamesOfType };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as SqlParamRefMutatorInternal, i as SqlParamRefMutator, n as ParamRefEntryUnion, o as createSqlParamRefMutator, r as ParamRefHandle, t as ParamRefEntry } from "./middleware-
|
|
2
|
-
import "./middleware-
|
|
1
|
+
import { a as SqlParamRefMutatorInternal, i as SqlParamRefMutator, n as ParamRefEntryUnion, o as createSqlParamRefMutator, r as ParamRefHandle, t as ParamRefEntry } from "./middleware-DHkW6pRr-CFiQojK4.mjs";
|
|
2
|
+
import "./middleware-GO31SJSv.mjs";
|
|
3
3
|
export { type ParamRefEntry, type ParamRefEntryUnion, type ParamRefHandle, type SqlParamRefMutator, type SqlParamRefMutatorInternal, createSqlParamRefMutator };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as SqlQueryPlan, r as planFromAst, t as Preparable } from "./plan-
|
|
2
|
-
import { t as SqlExecutionPlan } from "./sql-execution-plan-
|
|
3
|
-
import "./plan-
|
|
1
|
+
import { n as SqlQueryPlan, r as planFromAst, t as Preparable } from "./plan-Cr4azjnG-lIrzIrmu.mjs";
|
|
2
|
+
import { t as SqlExecutionPlan } from "./sql-execution-plan-3uxYjHyu-C0Z4_RSY.mjs";
|
|
3
|
+
import "./plan-OXQ8s6Ee.mjs";
|
|
4
4
|
export { Preparable, type SqlExecutionPlan, SqlQueryPlan, planFromAst };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as SqlAggregateDescriptorRegistry,
|
|
2
|
-
import "./query-lane-context
|
|
3
|
-
export { CodecDescriptorRegistry, ExecutionContext, ResolvedSqlAggregate, SqlAggregateDescriptorRegistry
|
|
1
|
+
import { a as SqlAggregateDescriptorRegistry, n as ExecutionContext, r as ResolvedSqlAggregate, t as CodecDescriptorRegistry } from "./query-lane-context-BCEoKy0_-DQOOliDn.mjs";
|
|
2
|
+
import "./query-lane-context-BssPNZey.mjs";
|
|
3
|
+
export { CodecDescriptorRegistry, ExecutionContext, ResolvedSqlAggregate, SqlAggregateDescriptorRegistry };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { S as TablesOf, _ as SqlOrmPlan, a as ColumnsOf, b as TableKey, c as META, d as ModelMetadata, f as OperationTypeSignature, g as SqlBuilderOptions, h as RuntimeScope, i as ColumnResolutionContract, l as Meta, m as OperationsForTypeId, n as BuildParamsMap, o as ComputeColumnJsType, p as OperationTypes, r as CodecTypes, s as Expr, t as BuildOptions, u as ModelDef, v as SqlPlan, x as TableMetadata, y as TableDef } from "./types-
|
|
2
|
-
import "./types-
|
|
1
|
+
import { S as TablesOf, _ as SqlOrmPlan, a as ColumnsOf, b as TableKey, c as META, d as ModelMetadata, f as OperationTypeSignature, g as SqlBuilderOptions, h as RuntimeScope, i as ColumnResolutionContract, l as Meta, m as OperationsForTypeId, n as BuildParamsMap, o as ComputeColumnJsType, p as OperationTypes, r as CodecTypes, s as Expr, t as BuildOptions, u as ModelDef, v as SqlPlan, x as TableMetadata, y as TableDef } from "./types-TXO7x1BA-DuW4v0rw.mjs";
|
|
2
|
+
import "./types-DDqbg3WC.mjs";
|
|
3
3
|
export { BuildOptions, BuildParamsMap, CodecTypes, ColumnResolutionContract, ColumnsOf, ComputeColumnJsType, Expr, META, Meta, ModelDef, ModelMetadata, OperationTypeSignature, OperationTypes, OperationsForTypeId, type RuntimeScope, SqlBuilderOptions, type SqlOrmPlan, SqlPlan, TableDef, TableKey, TableMetadata, TablesOf };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as StorageTable } from "./storage-table-
|
|
2
|
-
import { l as SqlStorage } from "./sql-storage-
|
|
1
|
+
import { r as StorageTable } from "./storage-table-Bf1ZjnxO-NvkG2pgq.mjs";
|
|
2
|
+
import { l as SqlStorage } from "./sql-storage-DeCAh5Hi-nJQUIgfL.mjs";
|
|
3
3
|
//#region ../../../2-sql/1-core/contract/dist/resolve-storage-table.d.mts
|
|
4
4
|
//#region src/resolve-storage-table.d.ts
|
|
5
5
|
interface ResolvedStorageTable {
|
|
@@ -18,4 +18,4 @@ interface ResolvedStorageTable {
|
|
|
18
18
|
declare function resolveStorageTable(storage: SqlStorage, tableName: string, namespaceId?: string): ResolvedStorageTable | undefined;
|
|
19
19
|
//#endregion
|
|
20
20
|
export { resolveStorageTable as n, ResolvedStorageTable as t };
|
|
21
|
-
//# sourceMappingURL=resolve-storage-table-
|
|
21
|
+
//# sourceMappingURL=resolve-storage-table-CxmU_MPu.d.mts.map
|
package/dist/{resolve-storage-table-8N2xelSh.d.mts.map → resolve-storage-table-CxmU_MPu.d.mts.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resolve-storage-table-
|
|
1
|
+
{"version":3,"file":"resolve-storage-table-CxmU_MPu.d.mts","names":[],"sources":["../../../../2-sql/1-core/contract/dist/resolve-storage-table.d.mts"],"mappings":";;;;UAGU;WACC;WACA,OAAO;;;;;;;;;;;iBAWD,oBAAoB,SAAS,YAAY,mBAAmB,uBAAuB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "./resolve-storage-table-
|
|
1
|
+
import "./resolve-storage-table-CxmU_MPu.mjs";
|
|
2
2
|
import { ResolvedDomainModel, UNBOUND_DOMAIN_NAMESPACE_ID, resolveDomainModel } from "@prisma/orm-framework/contract/types";
|
|
3
3
|
import { RuntimeMutationDefaultGenerator } from "@prisma/orm-framework/components/runtime";
|
|
4
4
|
import { RuntimeFamilyDescriptor, RuntimeFamilyInstance } from "@prisma/orm-framework/components/execution";
|
|
@@ -43,4 +43,4 @@ declare const sqlRuntimeFamilyDescriptor: RuntimeFamilyDescriptor<'sql', SqlRunt
|
|
|
43
43
|
declare function timestampNowRuntimeGenerator(): RuntimeMutationDefaultGenerator;
|
|
44
44
|
//#endregion
|
|
45
45
|
export { timestampNowRuntimeGenerator as a, sqlRuntimeFamilyDescriptor as i, UNBOUND_DOMAIN_NAMESPACE_ID as n, resolveDomainModel as r, ResolvedDomainModel as t };
|
|
46
|
-
//# sourceMappingURL=runtime-
|
|
46
|
+
//# sourceMappingURL=runtime-Bmndf-fm.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime-
|
|
1
|
+
{"version":3,"file":"runtime-Bmndf-fm.d.mts","names":[],"sources":["../../../../2-sql/9-family/dist/runtime.d.mts"],"mappings":";;;;;;;;;;;;;;UAaU,iCAAiC;;;;;;;;;;;cAW7B,4BAA4B,+BAA+B;;;;;;;;;;;;;;;;;iBAiBxD,gCAAgC"}
|
package/dist/runtime.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { m as MarkerReadResult } from "./ast-
|
|
2
|
-
import {
|
|
3
|
-
import { a as ParamSpec, c as PreparedExecution, i as DeclaredNullable, l as PreparedFor, n as Declaration, o as ParamsFromDeclaration, r as DeclaredCodecId, s as PrepareCallback, t as BindSiteParams, u as PreparedStatement } from "./transaction-state-DR3nKTmH-
|
|
4
|
-
import { $ as SqlExecutionStack, A as validateContractCodecMappings, B as MarkerReader, C as budgets, Ct as startActivityOn, D as lints, E as extractCodecIds, F as ActivitySourceTarget, G as RuntimeConnection, H as PreparedStatementImpl, I as BoundPreparedStatement, J as RuntimeOptions, K as RuntimeFamilyAdapter, L as CloseRefusal, M as ActivityHandle, N as ActivityRoute, O as lowerSqlPlan, P as ActivitySource, Q as RuntimeTransaction, R as ConnectionProvider, S as TransactionEnded, St as planContentHashOn, T as createToSql, Tt as withTransactionMembers, U as PreparedStatementInternals, V as PreparedExecutionImpl, W as Runtime, X as RuntimeQueryable, Y as RuntimeParameterizedCodecDescriptor, Z as RuntimeTelemetryEvent, _ as StartActivity, _t as delegatingActivitySource, a as ActivityParent, at as SqlRuntimeBase, b as ToSqlMember, bt as findActivitySource, c as ClientActivityEnd, ct as SqlRuntimeExtensionInstance, d as ClientActivityResult, dt as TelemetryOutcome, et as SqlExecutionStackWithDriver, f as ExecuteInterceptResult, ft as TransactionContext, g as RenderedSql, gt as createSqlExecutionStack, h as QueryInterceptResult, ht as createExecutionContext, i as ActivityInterceptResult, it as SqlRuntimeAdapterInstance, j as ActivityExecuteOptions, k as validateCodecRegistryCompleteness, l as ClientActivityEnded, lt as SqlRuntimeTargetDescriptor, m as Log, mt as activitySource, n as ActivityEndedResult, nt as SqlMiddlewareContext, o as BudgetsOptions, ot as SqlRuntimeDriverInstance, p as LintsOptions, pt as VerifyMarkerOption, q as RuntimeMode, r as ActivityFinalizedResult, rt as SqlRuntimeAdapterDescriptor, s as ClientActivity, st as SqlRuntimeExtensionDescriptor, t as Activity, tt as SqlMiddleware, u as ClientActivityKind, ut as SqlStaticContributions, v as StatementActivity, vt as deriveParamMetadata, w as createAstCodecRegistry, wt as withTransaction, x as TransactionActivity, xt as lazyActivitySource, y as StatementEnded, yt as encodeParamsWithMetadata, z as HashablePlan } from "./index-
|
|
5
|
-
export { type Activity, type ActivityEndedResult, type ActivityExecuteOptions, type ActivityFinalizedResult, type ActivityHandle, type ActivityInterceptResult, type ActivityParent, type ActivityRoute, type ActivitySource, type ActivitySourceTarget, type BindSiteParams, type BoundPreparedStatement, type BudgetsOptions, type ClientActivity, type ClientActivityEnd, type ClientActivityEnded, type ClientActivityKind, type ClientActivityResult, type CloseRefusal, type ConnectionProvider, type Declaration, type DeclaredCodecId, type DeclaredNullable, type ExecuteInterceptResult, type ExecutionContext, type HashablePlan, type LintsOptions, type Log, type MarkerReadResult, type MarkerReader, type ParamSpec, type ParamsFromDeclaration, type PrepareCallback, type PreparedExecution, PreparedExecutionImpl, type PreparedFor, type PreparedStatement, PreparedStatementImpl, type PreparedStatementInternals, type QueryInterceptResult, type RenderedSql, type Runtime, type RuntimeConnection, type RuntimeFamilyAdapter, type RuntimeMode, type RuntimeOptions, type RuntimeParameterizedCodecDescriptor, type RuntimeQueryable, type RuntimeTelemetryEvent, type RuntimeTransaction, type SqlExecutionStack, type SqlExecutionStackWithDriver, type SqlMiddleware, type SqlMiddlewareContext, type SqlRuntimeAdapterDescriptor, type SqlRuntimeAdapterInstance, SqlRuntimeBase, type SqlRuntimeDriverInstance, type SqlRuntimeExtensionDescriptor, type SqlRuntimeExtensionInstance, type SqlRuntimeTargetDescriptor, type SqlStaticContributions, type StartActivity, type StatementActivity, type StatementEnded, type TelemetryOutcome, type ToSqlMember, type TransactionActivity, type TransactionContext, type TransactionEnded, type
|
|
1
|
+
import { m as MarkerReadResult } from "./ast-BySjcUKx.mjs";
|
|
2
|
+
import { n as ExecutionContext } from "./query-lane-context-BCEoKy0_-DQOOliDn.mjs";
|
|
3
|
+
import { a as ParamSpec, c as PreparedExecution, i as DeclaredNullable, l as PreparedFor, n as Declaration, o as ParamsFromDeclaration, r as DeclaredCodecId, s as PrepareCallback, t as BindSiteParams, u as PreparedStatement } from "./transaction-state-DR3nKTmH-D6VdY7YX.mjs";
|
|
4
|
+
import { $ as SqlExecutionStack, A as validateContractCodecMappings, B as MarkerReader, C as budgets, Ct as startActivityOn, D as lints, E as extractCodecIds, F as ActivitySourceTarget, G as RuntimeConnection, H as PreparedStatementImpl, I as BoundPreparedStatement, J as RuntimeOptions, K as RuntimeFamilyAdapter, L as CloseRefusal, M as ActivityHandle, N as ActivityRoute, O as lowerSqlPlan, P as ActivitySource, Q as RuntimeTransaction, R as ConnectionProvider, S as TransactionEnded, St as planContentHashOn, T as createToSql, Tt as withTransactionMembers, U as PreparedStatementInternals, V as PreparedExecutionImpl, W as Runtime, X as RuntimeQueryable, Y as RuntimeParameterizedCodecDescriptor, Z as RuntimeTelemetryEvent, _ as StartActivity, _t as delegatingActivitySource, a as ActivityParent, at as SqlRuntimeBase, b as ToSqlMember, bt as findActivitySource, c as ClientActivityEnd, ct as SqlRuntimeExtensionInstance, d as ClientActivityResult, dt as TelemetryOutcome, et as SqlExecutionStackWithDriver, f as ExecuteInterceptResult, ft as TransactionContext, g as RenderedSql, gt as createSqlExecutionStack, h as QueryInterceptResult, ht as createExecutionContext, i as ActivityInterceptResult, it as SqlRuntimeAdapterInstance, j as ActivityExecuteOptions, k as validateCodecRegistryCompleteness, l as ClientActivityEnded, lt as SqlRuntimeTargetDescriptor, m as Log, mt as activitySource, n as ActivityEndedResult, nt as SqlMiddlewareContext, o as BudgetsOptions, ot as SqlRuntimeDriverInstance, p as LintsOptions, pt as VerifyMarkerOption, q as RuntimeMode, r as ActivityFinalizedResult, rt as SqlRuntimeAdapterDescriptor, s as ClientActivity, st as SqlRuntimeExtensionDescriptor, t as Activity, tt as SqlMiddleware, u as ClientActivityKind, ut as SqlStaticContributions, v as StatementActivity, vt as deriveParamMetadata, w as createAstCodecRegistry, wt as withTransaction, x as TransactionActivity, xt as lazyActivitySource, y as StatementEnded, yt as encodeParamsWithMetadata, z as HashablePlan } from "./index-3aEIvk82.mjs";
|
|
5
|
+
export { type Activity, type ActivityEndedResult, type ActivityExecuteOptions, type ActivityFinalizedResult, type ActivityHandle, type ActivityInterceptResult, type ActivityParent, type ActivityRoute, type ActivitySource, type ActivitySourceTarget, type BindSiteParams, type BoundPreparedStatement, type BudgetsOptions, type ClientActivity, type ClientActivityEnd, type ClientActivityEnded, type ClientActivityKind, type ClientActivityResult, type CloseRefusal, type ConnectionProvider, type Declaration, type DeclaredCodecId, type DeclaredNullable, type ExecuteInterceptResult, type ExecutionContext, type HashablePlan, type LintsOptions, type Log, type MarkerReadResult, type MarkerReader, type ParamSpec, type ParamsFromDeclaration, type PrepareCallback, type PreparedExecution, PreparedExecutionImpl, type PreparedFor, type PreparedStatement, PreparedStatementImpl, type PreparedStatementInternals, type QueryInterceptResult, type RenderedSql, type Runtime, type RuntimeConnection, type RuntimeFamilyAdapter, type RuntimeMode, type RuntimeOptions, type RuntimeParameterizedCodecDescriptor, type RuntimeQueryable, type RuntimeTelemetryEvent, type RuntimeTransaction, type SqlExecutionStack, type SqlExecutionStackWithDriver, type SqlMiddleware, type SqlMiddlewareContext, type SqlRuntimeAdapterDescriptor, type SqlRuntimeAdapterInstance, SqlRuntimeBase, type SqlRuntimeDriverInstance, type SqlRuntimeExtensionDescriptor, type SqlRuntimeExtensionInstance, type SqlRuntimeTargetDescriptor, type SqlStaticContributions, type StartActivity, type StatementActivity, type StatementEnded, type TelemetryOutcome, type ToSqlMember, type TransactionActivity, type TransactionContext, type TransactionEnded, type VerifyMarkerOption, activitySource, budgets, createAstCodecRegistry, createExecutionContext, createSqlExecutionStack, createToSql, delegatingActivitySource, deriveParamMetadata, encodeParamsWithMetadata, extractCodecIds, findActivitySource, lazyActivitySource, lints, lowerSqlPlan, planContentHashOn, startActivityOn, validateCodecRegistryCompleteness, validateContractCodecMappings, withTransaction, withTransactionMembers };
|
package/dist/runtime.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { C as withTransactionMembers, S as withTransaction, _ as lowerSqlPlan, a as budgets, b as validateCodecRegistryCompleteness, c as createSqlExecutionStack, d as deriveParamMetadata, f as encodeParamsWithMetadata, g as lints, h as lazyActivitySource, i as activitySource, l as createToSql, m as findActivitySource, n as PreparedStatementImpl, o as createAstCodecRegistry, p as extractCodecIds, r as SqlRuntimeBase, s as createExecutionContext, t as PreparedExecutionImpl, u as delegatingActivitySource, v as planContentHashOn, x as validateContractCodecMappings, y as startActivityOn } from "./exports-
|
|
1
|
+
import { C as withTransactionMembers, S as withTransaction, _ as lowerSqlPlan, a as budgets, b as validateCodecRegistryCompleteness, c as createSqlExecutionStack, d as deriveParamMetadata, f as encodeParamsWithMetadata, g as lints, h as lazyActivitySource, i as activitySource, l as createToSql, m as findActivitySource, n as PreparedStatementImpl, o as createAstCodecRegistry, p as extractCodecIds, r as SqlRuntimeBase, s as createExecutionContext, t as PreparedExecutionImpl, u as delegatingActivitySource, v as planContentHashOn, x as validateContractCodecMappings, y as startActivityOn } from "./exports-CRROThzp-BNz0pGj0.mjs";
|
|
2
2
|
export { PreparedExecutionImpl, PreparedStatementImpl, SqlRuntimeBase, activitySource, budgets, createAstCodecRegistry, createExecutionContext, createSqlExecutionStack, createToSql, delegatingActivitySource, deriveParamMetadata, encodeParamsWithMetadata, extractCodecIds, findActivitySource, lazyActivitySource, lints, lowerSqlPlan, planContentHashOn, startActivityOn, validateCodecRegistryCompleteness, validateContractCodecMappings, withTransaction, withTransactionMembers };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { S as transactionStart, _ as createTransactionStart, b as settlementOf, d as PreparedStatementExecuteTarget, f as PreparedStatementQueryTarget, g as TransactionStartTarget, h as TransactionStart, m as TransactionSettlementState, p as SettledTransactionTarget, v as preparedStatementExecute, x as transactionSettlement, y as preparedStatementQuery } from "./transaction-state-DR3nKTmH-
|
|
1
|
+
import { S as transactionStart, _ as createTransactionStart, b as settlementOf, d as PreparedStatementExecuteTarget, f as PreparedStatementQueryTarget, g as TransactionStartTarget, h as TransactionStart, m as TransactionSettlementState, p as SettledTransactionTarget, v as preparedStatementExecute, x as transactionSettlement, y as preparedStatementQuery } from "./transaction-state-DR3nKTmH-D6VdY7YX.mjs";
|
|
2
2
|
export { type PreparedStatementExecuteTarget, type PreparedStatementQueryTarget, type SettledTransactionTarget, type TransactionSettlementState, type TransactionStart, type TransactionStartTarget, createTransactionStart, preparedStatementExecute, preparedStatementQuery, settlementOf, transactionSettlement, transactionStart };
|
package/dist/{schema-differ-DmP74bB8-BfEQ_9cY.d.mts → schema-differ-DmP74bB8-0ZupRJKb.d.mts}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { l as SqlStorage } from "./sql-storage-
|
|
2
|
-
import "./types-
|
|
3
|
-
import { S as SqlSchemaIRNode } from "./types-
|
|
4
|
-
import "./types-
|
|
1
|
+
import { l as SqlStorage } from "./sql-storage-DeCAh5Hi-nJQUIgfL.mjs";
|
|
2
|
+
import "./types-CRbj_WQf.mjs";
|
|
3
|
+
import { S as SqlSchemaIRNode } from "./types-CuCxAQat-BBGUHEku.mjs";
|
|
4
|
+
import "./types-BUggiEEH.mjs";
|
|
5
5
|
import { Contract, ControlPolicy } from "@prisma/orm-framework/contract/types";
|
|
6
6
|
import { TargetBoundComponentDescriptor } from "@prisma/orm-framework/components/components";
|
|
7
7
|
import { SchemaDiffIssue } from "@prisma/orm-framework/components/control";
|
|
@@ -44,4 +44,4 @@ interface SqlSchemaDiffInput {
|
|
|
44
44
|
type SqlSchemaDiffFn = (input: SqlSchemaDiffInput) => SqlSchemaDiffResult;
|
|
45
45
|
//#endregion
|
|
46
46
|
export { SqlSchemaDiffInput as n, SqlSchemaDiffResult as r, SqlSchemaDiffFn as t };
|
|
47
|
-
//# sourceMappingURL=schema-differ-DmP74bB8-
|
|
47
|
+
//# sourceMappingURL=schema-differ-DmP74bB8-0ZupRJKb.d.mts.map
|
package/dist/{schema-differ-DmP74bB8-BfEQ_9cY.d.mts.map → schema-differ-DmP74bB8-0ZupRJKb.d.mts.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema-differ-DmP74bB8-
|
|
1
|
+
{"version":3,"file":"schema-differ-DmP74bB8-0ZupRJKb.d.mts","names":[],"sources":["../../../../2-sql/9-family/dist/schema-differ-DmP74bB8.d.mts"],"mappings":";;;;;;;;;;;;;;;;;UAcU;;WAEC,iBAAiB;;;;;;;;;WASjB,uBAAuB,OAAO,oBAAoB;;;;;;WAMlD,gBAAgB;aACd,QAAQ;;;UAGX;WACC,UAAU,SAAS;WACnB,QAAQ;WACR,qBAAqB,cAAc;;KAEzC,mBAAmB,OAAO,uBAAuB"}
|
package/dist/schema-ir.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { A as relationalNodeGranularity, C as SqlTableIR, D as assertNode, E as SqlUniqueIRInput, M as sqlDefaultValuesEqual, O as defineNonEnumerable, S as SqlSchemaIRNode, T as SqlUniqueIR, _ as SqlIndexIR, a as SqlAnnotations, b as SqlSchemaIR, c as SqlColumnDefaultIR, d as SqlColumnIRInput, f as SqlColumnType, g as SqlForeignKeyIRInput, h as SqlForeignKeyIR, i as ReportedSqlType, j as sqlColumnTypesEqual, k as relationalNodeEntityKind, l as SqlColumnDefaultIRInput, m as SqlExpressionLiteralFor, n as PrimaryKeyInput, o as SqlCheckConstraintIR, p as SqlDefaultValue, r as RelationalSchemaNodeKind, s as SqlCheckConstraintIRInput, t as PrimaryKey, u as SqlColumnIR, v as SqlIndexIRInput, w as SqlTableIRInput, x as SqlSchemaIRInput, y as SqlReferentialAction } from "./types-
|
|
1
|
+
import { A as relationalNodeGranularity, C as SqlTableIR, D as assertNode, E as SqlUniqueIRInput, M as sqlDefaultValuesEqual, O as defineNonEnumerable, S as SqlSchemaIRNode, T as SqlUniqueIR, _ as SqlIndexIR, a as SqlAnnotations, b as SqlSchemaIR, c as SqlColumnDefaultIR, d as SqlColumnIRInput, f as SqlColumnType, g as SqlForeignKeyIRInput, h as SqlForeignKeyIR, i as ReportedSqlType, j as sqlColumnTypesEqual, k as relationalNodeEntityKind, l as SqlColumnDefaultIRInput, m as SqlExpressionLiteralFor, n as PrimaryKeyInput, o as SqlCheckConstraintIR, p as SqlDefaultValue, r as RelationalSchemaNodeKind, s as SqlCheckConstraintIRInput, t as PrimaryKey, u as SqlColumnIR, v as SqlIndexIRInput, w as SqlTableIRInput, x as SqlSchemaIRInput, y as SqlReferentialAction } from "./types-CuCxAQat-BBGUHEku.mjs";
|
|
2
2
|
export { PrimaryKey, type PrimaryKeyInput, RelationalSchemaNodeKind, type ReportedSqlType, type SqlAnnotations, SqlCheckConstraintIR, type SqlCheckConstraintIRInput, SqlColumnDefaultIR, type SqlColumnDefaultIRInput, SqlColumnIR, type SqlColumnIRInput, type SqlColumnType, type SqlDefaultValue, type SqlExpressionLiteralFor, SqlForeignKeyIR, type SqlForeignKeyIRInput, SqlIndexIR, type SqlIndexIRInput, type SqlReferentialAction, SqlSchemaIR, type SqlSchemaIRInput, SqlSchemaIRNode, SqlTableIR, type SqlTableIRInput, SqlUniqueIR, type SqlUniqueIRInput, assertNode, defineNonEnumerable, relationalNodeEntityKind, relationalNodeGranularity, sqlColumnTypesEqual, sqlDefaultValuesEqual };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { A as relationalNodeGranularity, C as SqlTableIR, D as assertNode, E as SqlUniqueIRInput, M as sqlDefaultValuesEqual, O as defineNonEnumerable, S as SqlSchemaIRNode, T as SqlUniqueIR, _ as SqlIndexIR, a as SqlAnnotations, b as SqlSchemaIR, c as SqlColumnDefaultIR, d as SqlColumnIRInput, f as SqlColumnType, g as SqlForeignKeyIRInput, h as SqlForeignKeyIR, i as ReportedSqlType, j as sqlColumnTypesEqual, k as relationalNodeEntityKind, l as SqlColumnDefaultIRInput, m as SqlExpressionLiteralFor, n as PrimaryKeyInput, o as SqlCheckConstraintIR, p as SqlDefaultValue, r as RelationalSchemaNodeKind, s as SqlCheckConstraintIRInput, t as PrimaryKey, u as SqlColumnIR, v as SqlIndexIRInput, w as SqlTableIRInput, x as SqlSchemaIRInput, y as SqlReferentialAction } from "./types-
|
|
2
|
-
import "./types-
|
|
1
|
+
import { A as relationalNodeGranularity, C as SqlTableIR, D as assertNode, E as SqlUniqueIRInput, M as sqlDefaultValuesEqual, O as defineNonEnumerable, S as SqlSchemaIRNode, T as SqlUniqueIR, _ as SqlIndexIR, a as SqlAnnotations, b as SqlSchemaIR, c as SqlColumnDefaultIR, d as SqlColumnIRInput, f as SqlColumnType, g as SqlForeignKeyIRInput, h as SqlForeignKeyIR, i as ReportedSqlType, j as sqlColumnTypesEqual, k as relationalNodeEntityKind, l as SqlColumnDefaultIRInput, m as SqlExpressionLiteralFor, n as PrimaryKeyInput, o as SqlCheckConstraintIR, p as SqlDefaultValue, r as RelationalSchemaNodeKind, s as SqlCheckConstraintIRInput, t as PrimaryKey, u as SqlColumnIR, v as SqlIndexIRInput, w as SqlTableIRInput, x as SqlSchemaIRInput, y as SqlReferentialAction } from "./types-CuCxAQat-BBGUHEku.mjs";
|
|
2
|
+
import "./types-BUggiEEH.mjs";
|
|
3
3
|
export { PrimaryKey, type PrimaryKeyInput, RelationalSchemaNodeKind, type ReportedSqlType, type SqlAnnotations, SqlCheckConstraintIR, type SqlCheckConstraintIRInput, SqlColumnDefaultIR, type SqlColumnDefaultIRInput, SqlColumnIR, type SqlColumnIRInput, type SqlColumnType, type SqlDefaultValue, type SqlExpressionLiteralFor, SqlForeignKeyIR, type SqlForeignKeyIRInput, SqlIndexIR, type SqlIndexIRInput, type SqlReferentialAction, SqlSchemaIR, type SqlSchemaIRInput, SqlSchemaIRNode, SqlTableIR, type SqlTableIRInput, SqlUniqueIR, type SqlUniqueIRInput, assertNode, defineNonEnumerable, relationalNodeEntityKind, relationalNodeGranularity, sqlColumnTypesEqual, sqlDefaultValuesEqual };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { n as isSqlDataType, t as findSqlDataTypeCollision } from "./sql-data-type-D7M-YTTY-C9oWGZ3z.mjs";
|
|
2
2
|
import { i as assertNothingCastsFromSqlExpression } from "./sql-expression-BJCuy-WI.mjs";
|
|
3
|
-
import { u as isStorageTypeInstance } from "./types-
|
|
3
|
+
import { u as isStorageTypeInstance } from "./types-C7610W2l.mjs";
|
|
4
4
|
import { ifDefined } from "@prisma/orm-framework/utils/defined";
|
|
5
5
|
import { blindCast } from "@prisma/orm-framework/utils/casts";
|
|
6
6
|
import { InternalError } from "@prisma/orm-framework/utils/internal-error";
|
|
7
7
|
import { effectiveControlPolicy } from "@prisma/orm-framework/contract/types";
|
|
8
8
|
import { runtimeError } from "@prisma/orm-framework/components/components";
|
|
9
9
|
import { VERIFY_CODE_SCHEMA_FAILURE, assertUniqueCodecOwner, dispositionForCategory, issueOutcome } from "@prisma/orm-framework/components/control";
|
|
10
|
-
//#region ../../../2-sql/9-family/dist/schema-verify-
|
|
10
|
+
//#region ../../../2-sql/9-family/dist/schema-verify-C3wbdviw.mjs
|
|
11
11
|
function hasCodecControlHooks(descriptor) {
|
|
12
12
|
if (typeof descriptor !== "object" || descriptor === null) return false;
|
|
13
13
|
const hooks = blindCast(descriptor).types?.codecTypes?.controlPlaneHooks;
|
|
@@ -259,4 +259,4 @@ function verifySqlSchemaByDiff(input) {
|
|
|
259
259
|
//#endregion
|
|
260
260
|
export { computeStorageTypeVerdict as a, verifySqlSchemaByDiff as c, computeSqlDiffVerdict as i, classifyDiffSubjectGranularity as n, enforceSqlDataTypeInvariants as o, classifySqlDiffIssue as r, extractCodecControlHooks as s, classifyDiffEntityKind as t };
|
|
261
261
|
|
|
262
|
-
//# sourceMappingURL=schema-verify-
|
|
262
|
+
//# sourceMappingURL=schema-verify-C3wbdviw-BifQBCpu.mjs.map
|
package/dist/{schema-verify-BwRdzbHb-DfFAS0EC.mjs.map → schema-verify-C3wbdviw-BifQBCpu.mjs.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema-verify-BwRdzbHb-DfFAS0EC.mjs","names":[],"sources":["../../../../2-sql/9-family/dist/schema-verify-BwRdzbHb.mjs"],"sourcesContent":["import { assertNothingCastsFromSqlExpression } from \"@internal/sql-contract/sql-expression\";\nimport { VERIFY_CODE_SCHEMA_FAILURE, assertUniqueCodecOwner, dispositionForCategory, issueOutcome } from \"@internal/framework-components/control\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { ifDefined } from \"@internal/utils/defined\";\nimport { InternalError } from \"@internal/utils/internal-error\";\nimport { runtimeError } from \"@internal/framework-components/components\";\nimport { findSqlDataTypeCollision, isSqlDataType } from \"@internal/sql-contract/data-type\";\nimport { isStorageTypeInstance } from \"@internal/sql-contract/types\";\nimport { effectiveControlPolicy } from \"@internal/contract/types\";\n//#region src/core/assembly.ts\nfunction hasCodecControlHooks(descriptor) {\n\tif (typeof descriptor !== \"object\" || descriptor === null) return false;\n\tconst hooks = blindCast(descriptor).types?.codecTypes?.controlPlaneHooks;\n\treturn hooks !== null && hooks !== void 0 && typeof hooks === \"object\";\n}\nfunction extractCodecControlHooks(descriptors) {\n\tconst hooks = /* @__PURE__ */ new Map();\n\tconst owners = /* @__PURE__ */ new Map();\n\tfor (const descriptor of descriptors) {\n\t\tif (typeof descriptor !== \"object\" || descriptor === null) continue;\n\t\tif (!hasCodecControlHooks(descriptor)) continue;\n\t\tconst controlPlaneHooks = descriptor.types.codecTypes.controlPlaneHooks;\n\t\tfor (const [codecId, hook] of Object.entries(controlPlaneHooks)) {\n\t\t\tassertUniqueCodecOwner({\n\t\t\t\tcodecId,\n\t\t\t\towners,\n\t\t\t\tdescriptorId: descriptor.id,\n\t\t\t\tentityLabel: \"control hooks\",\n\t\t\t\tentityOwnershipLabel: \"owner\"\n\t\t\t});\n\t\t\thooks.set(codecId, hook);\n\t\t\towners.set(codecId, descriptor.id);\n\t\t}\n\t}\n\treturn hooks;\n}\n/**\n* The SQL family's checks of the stack's data types and codecs, each naming the contributor:\n* no two SQL data types would both recognise one reported type, by colliding claiming texts or by\n* claiming the same kind; no data type casts from `sql/expression`; every type stored as another\n* names a registered SQL data type; and every codec represents a\n* SQL data type, because a codec represents a column's type and `sql/expression` is the one data\n* type no column has.\n*/\nfunction enforceSqlDataTypeInvariants(declaredDataTypes, codecDescriptors) {\n\tconst declaredById = new Map(declaredDataTypes.map((declared) => [declared.type.id, declared]));\n\tconst capitalized = (text) => `${text.charAt(0).toUpperCase()}${text.slice(1)}`;\n\tconst describe = (type) => `data type \"${type.id}\" contributed by \"${declaredById.get(type.id)?.contributedBy ?? \"<unknown>\"}\"`;\n\tconst collision = findSqlDataTypeCollision(declaredDataTypes.map(({ type }) => type));\n\tif (collision !== void 0) {\n\t\tconst { first, second, claims } = collision;\n\t\tif (claims.by === \"kind\") throw new InternalError(`The ${describe(first)} and the ${describe(second)} both claim the kind \"${claims.kind}\".`);\n\t\tthrow new InternalError(`The ${describe(first)} claims the text \"${claims.first}\", which collides with the text \"${claims.second}\" claimed by the ${describe(second)}.`);\n\t}\n\tassertNothingCastsFromSqlExpression(declaredDataTypes);\n\tfor (const { type, contributedBy } of declaredDataTypes) {\n\t\tif (!isSqlDataType(type) || type.sql.storedAs === void 0) continue;\n\t\tconst storage = declaredById.get(type.sql.storedAs)?.type;\n\t\tif (storage !== void 0 && isSqlDataType(storage)) {\n\t\t\tconst further = storage.sql.storedAs;\n\t\t\tif (further === void 0) continue;\n\t\t\tthrow new InternalError(`${capitalized(describe(type))} is stored as \"${storage.id}\", which is itself stored as \"${further}\". Name \"${further}\" as the type it is stored as.`);\n\t\t}\n\t\tthrow runtimeError(\"CONTRACT.DATA_TYPE_UNREGISTERED\", `Data type \"${type.id}\" is stored as data type \"${type.sql.storedAs}\", which no component registers. Contributed by \"${contributedBy}\".`, {\n\t\t\tdataType: type.sql.storedAs,\n\t\t\tcontributedBy\n\t\t});\n\t}\n\tfor (const codec of codecDescriptors) {\n\t\tconst represented = declaredById.get(codec.dataType)?.type;\n\t\tif (represented === void 0 || isSqlDataType(represented)) continue;\n\t\tthrow new InternalError(`Codec \"${codec.codecId}\" represents ${describe(represented)}, which is not a SQL data type. In a SQL stack a codec represents a column's type, so its data type is declared with sqlDataType.`);\n\t}\n}\n//#endregion\n//#region src/core/diff/verifier-disposition.ts\n/**\n* Classifies a codec `verifyType` hook finding into the target-neutral\n* categories the framework grades. A storage type is a named type instance\n* (e.g. a native enum); the only shape divergence it can carry is a change\n* to its value set, so a paired mismatch always classifies as `valueDrift`.\n*/\nfunction classifyStorageTypeDiffIssue(issue) {\n\tif (issueOutcome(issue) === \"not-found\") return \"declaredMissing\";\n\tif (issueOutcome(issue) === \"not-expected\") return \"extraAuxiliary\";\n\treturn \"valueDrift\";\n}\nfunction verifierDisposition(controlPolicy, issue) {\n\treturn dispositionForCategory(controlPolicy, classifyStorageTypeDiffIssue(issue));\n}\n//#endregion\n//#region src/core/diff/schema-verify.ts\nfunction issueNode(issue) {\n\tconst node = issue.expected ?? issue.actual;\n\tif (node === void 0) return void 0;\n\treturn blindCast(node);\n}\n/**\n* Resolves an issue's framework-neutral {@link DiffSubjectGranularity} on\n* demand, from the issue's node's `nodeKind` via the target-provided\n* `granularityOf` map. The node carries only its `nodeKind` identity, never a\n* classification, and nothing is stamped onto the issue — every consumer\n* (the family verdict below, the framework aggregate's unclaimed-elements\n* sweep via {@link import('@internal/framework-components/control').SchemaSubjectClassifierCapable})\n* calls this the same way, resolved by the family/target that owns the node\n* vocabulary. `undefined` for an issue with no node.\n*/\nfunction classifyDiffSubjectGranularity(issue, granularityOf) {\n\tconst node = issueNode(issue);\n\treturn node === void 0 ? void 0 : granularityOf(node.nodeKind);\n}\n/**\n* Resolves an issue's storage `entityKind` on demand, from the issue's\n* node's `nodeKind` via the target-provided `entityKindOf` map — the sibling\n* of {@link classifyDiffSubjectGranularity}, called the same way by the same\n* consumers (via\n* {@link import('@internal/framework-components/control').SchemaSubjectClassifierCapable}).\n* `undefined` for an issue with no node, or for a node kind with no storage\n* entity of its own.\n*/\nfunction classifyDiffEntityKind(issue, entityKindOf) {\n\tconst node = issueNode(issue);\n\treturn node === void 0 ? void 0 : entityKindOf(node.nodeKind);\n}\n/**\n* Re-keys the legacy `classifySqlVerifierIssueKind` category mapping on the\n* issue's {@link DiffSubjectGranularity} (resolved via `granularityOf`) + the\n* issue reason. The vocabulary maps one-to-one: an undeclared live entity or\n* namespace is `extraTopLevelObject`, an undeclared live field\n* `extraNestedElement`, undeclared auxiliaries (constraints, indexes,\n* defaults) and structural leaves (policies) `extraAuxiliary`; every paired\n* divergence is `declaredIncompatible`; anything the database lacks is\n* `declaredMissing`.\n* `granularityOf` is the target's classifier, so target and extension node\n* kinds classify without the family importing them.\n*/\nfunction classifySqlDiffIssue(issue, granularityOf) {\n\tif (issueOutcome(issue) === \"not-found\") return \"declaredMissing\";\n\tif (issueOutcome(issue) === \"not-expected\") {\n\t\tconst granularity = classifyDiffSubjectGranularity(issue, granularityOf);\n\t\tif (granularity === \"entity\" || granularity === \"namespace\") return \"extraTopLevelObject\";\n\t\tif (granularity === \"field\") return \"extraNestedElement\";\n\t\treturn \"extraAuxiliary\";\n\t}\n\treturn \"declaredIncompatible\";\n}\n/**\n* Whether a `not-expected` issue is a strict-mode-only finding. The legacy\n* walk detected every relational extra (namespaces, entities, fields, and\n* their auxiliaries) only under `--strict`; the structural diff (roots, RLS\n* policies, roles) was never strict-gated — its extras fail in both modes.\n* Keyed on the issue's granularity, resolved via `granularityOf`.\n*/\nfunction isStrictOnlyExtra(issue, granularityOf) {\n\tconst granularity = classifyDiffSubjectGranularity(issue, granularityOf);\n\treturn granularity === \"namespace\" || granularity === \"entity\" || granularity === \"field\" || granularity === \"auxiliary\";\n}\n/**\n* Applies the two consumer filters to a diff issue list: strict gating\n* (relational `not-expected` findings drop in lenient mode) and\n* control-policy disposition (each surviving issue grades against its\n* subject table's effective policy; suppressed issues drop, `observed`\n* subjects warn). The verify verdict is `failures.length === 0`.\n*/\nfunction computeSqlDiffVerdict(input) {\n\tconst failures = [];\n\tconst warnings = [];\n\tfor (const issue of input.issues) {\n\t\tif (!input.strict && issueOutcome(issue) === \"not-expected\" && isStrictOnlyExtra(issue, input.granularityOf)) continue;\n\t\tconst disposition = dispositionForCategory(effectiveControlPolicy(input.resolveControlPolicy(issue), input.defaultControlPolicy), classifySqlDiffIssue(issue, input.granularityOf));\n\t\tif (disposition === \"suppress\") continue;\n\t\tif (disposition === \"warn\") {\n\t\t\twarnings.push(issue);\n\t\t\tcontinue;\n\t\t}\n\t\tfailures.push(issue);\n\t}\n\treturn {\n\t\tfailures,\n\t\twarnings\n\t};\n}\nfunction computeStorageTypeVerdict(input) {\n\tconst failures = [];\n\tconst warnings = [];\n\tconst policy = effectiveControlPolicy(void 0, input.contract.defaultControlPolicy);\n\tfor (const pair of input.namespacePairs) {\n\t\tif (pair.actual === void 0) continue;\n\t\tfor (const [typeName, typeInstance] of Object.entries(input.contract.storage.types ?? {})) {\n\t\t\tif (!isStorageTypeInstance(typeInstance)) continue;\n\t\t\tconst hook = input.codecHooks.get(typeInstance.codecId);\n\t\t\tif (!hook?.verifyType) continue;\n\t\t\tconst typeIssues = hook.verifyType({\n\t\t\t\ttypeName,\n\t\t\t\ttypeInstance,\n\t\t\t\tschema: pair.actual\n\t\t\t});\n\t\t\tfor (const issue of typeIssues) {\n\t\t\t\tconst disposition = verifierDisposition(policy, issue);\n\t\t\t\tif (disposition === \"suppress\") continue;\n\t\t\t\tif (disposition === \"warn\") {\n\t\t\t\t\twarnings.push(issue);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tfailures.push(issue);\n\t\t\t}\n\t\t}\n\t}\n\treturn {\n\t\tfailures,\n\t\twarnings\n\t};\n}\n/**\n* THE SQL schema verify: runs the target's full-tree node diff, grades it\n* through the family's post-diff filters (strict gating + control-policy\n* disposition) plus the codec `verifyType` hook findings, and wraps the\n* verdict in the issue-based result envelope. `ok` holds exactly when both\n* issue lists are empty — the lists carry the verdict's failures.\n*/\nfunction verifySqlSchemaByDiff(input) {\n\tconst startTime = Date.now();\n\tconst verdictDiff = input.diffSchema({\n\t\tcontract: input.contract,\n\t\tschema: input.schema,\n\t\tframeworkComponents: input.frameworkComponents\n\t});\n\tconst diffVerdict = computeSqlDiffVerdict({\n\t\tissues: verdictDiff.issues,\n\t\tresolveControlPolicy: verdictDiff.resolveControlPolicy,\n\t\tstrict: input.strict,\n\t\tdefaultControlPolicy: input.contract.defaultControlPolicy,\n\t\tgranularityOf: input.granularityOf\n\t});\n\tconst storageTypeVerdict = computeStorageTypeVerdict({\n\t\tcontract: input.contract,\n\t\tnamespacePairs: verdictDiff.namespacePairs,\n\t\tcodecHooks: extractCodecControlHooks(input.frameworkComponents)\n\t});\n\tconst failCount = diffVerdict.failures.length + storageTypeVerdict.failures.length;\n\tconst ok = failCount === 0;\n\tconst profileHash = \"profileHash\" in input.contract && typeof input.contract.profileHash === \"string\" ? input.contract.profileHash : void 0;\n\treturn {\n\t\tok,\n\t\t...ok ? {} : { code: VERIFY_CODE_SCHEMA_FAILURE },\n\t\tsummary: ok ? \"Database schema satisfies contract\" : `Database schema does not satisfy contract (${failCount} failure${failCount === 1 ? \"\" : \"s\"})`,\n\t\tcontract: {\n\t\t\tstorageHash: input.contract.storage.storageHash,\n\t\t\t...ifDefined(\"profileHash\", profileHash)\n\t\t},\n\t\ttarget: {\n\t\t\texpected: input.contract.target,\n\t\t\tactual: input.contract.target\n\t\t},\n\t\tschema: {\n\t\t\tissues: [...diffVerdict.failures, ...storageTypeVerdict.failures],\n\t\t\twarnings: { issues: [...diffVerdict.warnings, ...storageTypeVerdict.warnings] }\n\t\t},\n\t\tmeta: { strict: input.strict },\n\t\ttimings: { total: Date.now() - startTime }\n\t};\n}\n//#endregion\nexport { computeStorageTypeVerdict as a, extractCodecControlHooks as c, computeSqlDiffVerdict as i, classifyDiffSubjectGranularity as n, verifySqlSchemaByDiff as o, classifySqlDiffIssue as r, enforceSqlDataTypeInvariants as s, classifyDiffEntityKind as t };\n\n//# sourceMappingURL=schema-verify-BwRdzbHb.mjs.map"],"mappings":";;;;;;;;;;AAUA,SAAS,qBAAqB,YAAY;CACzC,IAAI,OAAO,eAAe,YAAY,eAAe,MAAM,OAAO;CAClE,MAAM,QAAQ,UAAU,UAAU,CAAC,CAAC,OAAO,YAAY;CACvD,OAAO,UAAU,QAAQ,UAAU,KAAK,KAAK,OAAO,UAAU;AAC/D;AACA,SAAS,yBAAyB,aAAa;CAC9C,MAAM,wBAAwB,IAAI,IAAI;CACtC,MAAM,yBAAyB,IAAI,IAAI;CACvC,KAAK,MAAM,cAAc,aAAa;EACrC,IAAI,OAAO,eAAe,YAAY,eAAe,MAAM;EAC3D,IAAI,CAAC,qBAAqB,UAAU,GAAG;EACvC,MAAM,oBAAoB,WAAW,MAAM,WAAW;EACtD,KAAK,MAAM,CAAC,SAAS,SAAS,OAAO,QAAQ,iBAAiB,GAAG;GAChE,uBAAuB;IACtB;IACA;IACA,cAAc,WAAW;IACzB,aAAa;IACb,sBAAsB;GACvB,CAAC;GACD,MAAM,IAAI,SAAS,IAAI;GACvB,OAAO,IAAI,SAAS,WAAW,EAAE;EAClC;CACD;CACA,OAAO;AACR;;;;;;;;;AASA,SAAS,6BAA6B,mBAAmB,kBAAkB;CAC1E,MAAM,eAAe,IAAI,IAAI,kBAAkB,KAA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js"],"sourcesContent":["import { findSqlDataTypeCollision, isSqlDataType } from \"@internal/sql-contract/data-type\";\nimport { assertNothingCastsFromSqlExpression } from \"@internal/sql-contract/sql-expression\";\nimport { VERIFY_CODE_SCHEMA_FAILURE, assertUniqueCodecOwner, dispositionForCategory, issueOutcome } from \"@internal/framework-components/control\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { ifDefined } from \"@internal/utils/defined\";\nimport { InternalError } from \"@internal/utils/internal-error\";\nimport { runtimeError } from \"@internal/framework-components/components\";\nimport { isStorageTypeInstance } from \"@internal/sql-contract/types\";\nimport { effectiveControlPolicy } from \"@internal/contract/types\";\n//#region src/core/assembly.ts\nfunction hasCodecControlHooks(descriptor) {\n\tif (typeof descriptor !== \"object\" || descriptor === null) return false;\n\tconst hooks = blindCast(descriptor).types?.codecTypes?.controlPlaneHooks;\n\treturn hooks !== null && hooks !== void 0 && typeof hooks === \"object\";\n}\nfunction extractCodecControlHooks(descriptors) {\n\tconst hooks = /* @__PURE__ */ new Map();\n\tconst owners = /* @__PURE__ */ new Map();\n\tfor (const descriptor of descriptors) {\n\t\tif (typeof descriptor !== \"object\" || descriptor === null) continue;\n\t\tif (!hasCodecControlHooks(descriptor)) continue;\n\t\tconst controlPlaneHooks = descriptor.types.codecTypes.controlPlaneHooks;\n\t\tfor (const [codecId, hook] of Object.entries(controlPlaneHooks)) {\n\t\t\tassertUniqueCodecOwner({\n\t\t\t\tcodecId,\n\t\t\t\towners,\n\t\t\t\tdescriptorId: descriptor.id,\n\t\t\t\tentityLabel: \"control hooks\",\n\t\t\t\tentityOwnershipLabel: \"owner\"\n\t\t\t});\n\t\t\thooks.set(codecId, hook);\n\t\t\towners.set(codecId, descriptor.id);\n\t\t}\n\t}\n\treturn hooks;\n}\n/**\n* The SQL family's checks of the stack's data types and codecs, each naming the contributor:\n* no two SQL data types would both recognise one reported type, by colliding claiming texts or by\n* claiming the same kind; no data type casts from `sql/expression`; every type stored as another\n* names a registered SQL data type; and every codec represents a\n* SQL data type, because a codec represents a column's type and `sql/expression` is the one data\n* type no column has.\n*/\nfunction enforceSqlDataTypeInvariants(declaredDataTypes, codecDescriptors) {\n\tconst declaredById = new Map(declaredDataTypes.map((declared) => [declared.type.id, declared]));\n\tconst capitalized = (text) => `${text.charAt(0).toUpperCase()}${text.slice(1)}`;\n\tconst describe = (type) => `data type \"${type.id}\" contributed by \"${declaredById.get(type.id)?.contributedBy ?? \"<unknown>\"}\"`;\n\tconst collision = findSqlDataTypeCollision(declaredDataTypes.map(({ type }) => type));\n\tif (collision !== void 0) {\n\t\tconst { first, second, claims } = collision;\n\t\tif (claims.by === \"kind\") throw new InternalError(`The ${describe(first)} and the ${describe(second)} both claim the kind \"${claims.kind}\".`);\n\t\tthrow new InternalError(`The ${describe(first)} claims the text \"${claims.first}\", which collides with the text \"${claims.second}\" claimed by the ${describe(second)}.`);\n\t}\n\tassertNothingCastsFromSqlExpression(declaredDataTypes);\n\tfor (const { type, contributedBy } of declaredDataTypes) {\n\t\tif (!isSqlDataType(type) || type.sql.storedAs === void 0) continue;\n\t\tconst storage = declaredById.get(type.sql.storedAs)?.type;\n\t\tif (storage !== void 0 && isSqlDataType(storage)) {\n\t\t\tconst further = storage.sql.storedAs;\n\t\t\tif (further === void 0) continue;\n\t\t\tthrow new InternalError(`${capitalized(describe(type))} is stored as \"${storage.id}\", which is itself stored as \"${further}\". Name \"${further}\" as the type it is stored as.`);\n\t\t}\n\t\tthrow runtimeError(\"CONTRACT.DATA_TYPE_UNREGISTERED\", `Data type \"${type.id}\" is stored as data type \"${type.sql.storedAs}\", which no component registers. Contributed by \"${contributedBy}\".`, {\n\t\t\tdataType: type.sql.storedAs,\n\t\t\tcontributedBy\n\t\t});\n\t}\n\tfor (const codec of codecDescriptors) {\n\t\tconst represented = declaredById.get(codec.dataType)?.type;\n\t\tif (represented === void 0 || isSqlDataType(represented)) continue;\n\t\tthrow new InternalError(`Codec \"${codec.codecId}\" represents ${describe(represented)}, which is not a SQL data type. In a SQL stack a codec represents a column's type, so its data type is declared with sqlDataType.`);\n\t}\n}\n//#endregion\n//#region src/core/diff/verifier-disposition.ts\n/**\n* Classifies a codec `verifyType` hook finding into the target-neutral\n* categories the framework grades. A storage type is a named type instance\n* (e.g. a native enum); the only shape divergence it can carry is a change\n* to its value set, so a paired mismatch always classifies as `valueDrift`.\n*/\nfunction classifyStorageTypeDiffIssue(issue) {\n\tif (issueOutcome(issue) === \"not-found\") return \"declaredMissing\";\n\tif (issueOutcome(issue) === \"not-expected\") return \"extraAuxiliary\";\n\treturn \"valueDrift\";\n}\nfunction verifierDisposition(controlPolicy, issue) {\n\treturn dispositionForCategory(controlPolicy, classifyStorageTypeDiffIssue(issue));\n}\n//#endregion\n//#region src/core/diff/schema-verify.ts\nfunction issueNode(issue) {\n\tconst node = issue.expected ?? issue.actual;\n\tif (node === void 0) return void 0;\n\treturn blindCast(node);\n}\n/**\n* Resolves an issue's framework-neutral {@link DiffSubjectGranularity} on\n* demand, from the issue's node's `nodeKind` via the target-provided\n* `granularityOf` map. The node carries only its `nodeKind` identity, never a\n* classification, and nothing is stamped onto the issue — every consumer\n* (the family verdict below, the framework aggregate's unclaimed-elements\n* sweep via {@link import('@internal/framework-components/control').SchemaSubjectClassifierCapable})\n* calls this the same way, resolved by the family/target that owns the node\n* vocabulary. `undefined` for an issue with no node.\n*/\nfunction classifyDiffSubjectGranularity(issue, granularityOf) {\n\tconst node = issueNode(issue);\n\treturn node === void 0 ? void 0 : granularityOf(node.nodeKind);\n}\n/**\n* Resolves an issue's storage `entityKind` on demand, from the issue's\n* node's `nodeKind` via the target-provided `entityKindOf` map — the sibling\n* of {@link classifyDiffSubjectGranularity}, called the same way by the same\n* consumers (via\n* {@link import('@internal/framework-components/control').SchemaSubjectClassifierCapable}).\n* `undefined` for an issue with no node, or for a node kind with no storage\n* entity of its own.\n*/\nfunction classifyDiffEntityKind(issue, entityKindOf) {\n\tconst node = issueNode(issue);\n\treturn node === void 0 ? void 0 : entityKindOf(node.nodeKind);\n}\n/**\n* Re-keys the legacy `classifySqlVerifierIssueKind` category mapping on the\n* issue's {@link DiffSubjectGranularity} (resolved via `granularityOf`) + the\n* issue reason. The vocabulary maps one-to-one: an undeclared live entity or\n* namespace is `extraTopLevelObject`, an undeclared live field\n* `extraNestedElement`, undeclared auxiliaries (constraints, indexes,\n* defaults) and structural leaves (policies) `extraAuxiliary`; every paired\n* divergence is `declaredIncompatible`; anything the database lacks is\n* `declaredMissing`.\n* `granularityOf` is the target's classifier, so target and extension node\n* kinds classify without the family importing them.\n*/\nfunction classifySqlDiffIssue(issue, granularityOf) {\n\tif (issueOutcome(issue) === \"not-found\") return \"declaredMissing\";\n\tif (issueOutcome(issue) === \"not-expected\") {\n\t\tconst granularity = classifyDiffSubjectGranularity(issue, granularityOf);\n\t\tif (granularity === \"entity\" || granularity === \"namespace\") return \"extraTopLevelObject\";\n\t\tif (granularity === \"field\") return \"extraNestedElement\";\n\t\treturn \"extraAuxiliary\";\n\t}\n\treturn \"declaredIncompatible\";\n}\n/**\n* Whether a `not-expected` issue is a strict-mode-only finding. The legacy\n* walk detected every relational extra (namespaces, entities, fields, and\n* their auxiliaries) only under `--strict`; the structural diff (roots, RLS\n* policies, roles) was never strict-gated — its extras fail in both modes.\n* Keyed on the issue's granularity, resolved via `granularityOf`.\n*/\nfunction isStrictOnlyExtra(issue, granularityOf) {\n\tconst granularity = classifyDiffSubjectGranularity(issue, granularityOf);\n\treturn granularity === \"namespace\" || granularity === \"entity\" || granularity === \"field\" || granularity === \"auxiliary\";\n}\n/**\n* Applies the two consumer filters to a diff issue list: strict gating\n* (relational `not-expected` findings drop in lenient mode) and\n* control-policy disposition (each surviving issue grades against its\n* subject table's effective policy; suppressed issues drop, `observed`\n* subjects warn). The verify verdict is `failures.length === 0`.\n*/\nfunction computeSqlDiffVerdict(input) {\n\tconst failures = [];\n\tconst warnings = [];\n\tfor (const issue of input.issues) {\n\t\tif (!input.strict && issueOutcome(issue) === \"not-expected\" && isStrictOnlyExtra(issue, input.granularityOf)) continue;\n\t\tconst disposition = dispositionForCategory(effectiveControlPolicy(input.resolveControlPolicy(issue), input.defaultControlPolicy), classifySqlDiffIssue(issue, input.granularityOf));\n\t\tif (disposition === \"suppress\") continue;\n\t\tif (disposition === \"warn\") {\n\t\t\twarnings.push(issue);\n\t\t\tcontinue;\n\t\t}\n\t\tfailures.push(issue);\n\t}\n\treturn {\n\t\tfailures,\n\t\twarnings\n\t};\n}\nfunction computeStorageTypeVerdict(input) {\n\tconst failures = [];\n\tconst warnings = [];\n\tconst policy = effectiveControlPolicy(void 0, input.contract.defaultControlPolicy);\n\tfor (const pair of input.namespacePairs) {\n\t\tif (pair.actual === void 0) continue;\n\t\tfor (const [typeName, typeInstance] of Object.entries(input.contract.storage.types ?? {})) {\n\t\t\tif (!isStorageTypeInstance(typeInstance)) continue;\n\t\t\tconst hook = input.codecHooks.get(typeInstance.codecId);\n\t\t\tif (!hook?.verifyType) continue;\n\t\t\tconst typeIssues = hook.verifyType({\n\t\t\t\ttypeName,\n\t\t\t\ttypeInstance,\n\t\t\t\tschema: pair.actual\n\t\t\t});\n\t\t\tfor (const issue of typeIssues) {\n\t\t\t\tconst disposition = verifierDisposition(policy, issue);\n\t\t\t\tif (disposition === \"suppress\") continue;\n\t\t\t\tif (disposition === \"warn\") {\n\t\t\t\t\twarnings.push(issue);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tfailures.push(issue);\n\t\t\t}\n\t\t}\n\t}\n\treturn {\n\t\tfailures,\n\t\twarnings\n\t};\n}\n/**\n* THE SQL schema verify: runs the target's full-tree node diff, grades it\n* through the family's post-diff filters (strict gating + control-policy\n* disposition) plus the codec `verifyType` hook findings, and wraps the\n* verdict in the issue-based result envelope. `ok` holds exactly when both\n* issue lists are empty — the lists carry the verdict's failures.\n*/\nfunction verifySqlSchemaByDiff(input) {\n\tconst startTime = Date.now();\n\tconst verdictDiff = input.diffSchema({\n\t\tcontract: input.contract,\n\t\tschema: input.schema,\n\t\tframeworkComponents: input.frameworkComponents\n\t});\n\tconst diffVerdict = computeSqlDiffVerdict({\n\t\tissues: verdictDiff.issues,\n\t\tresolveControlPolicy: verdictDiff.resolveControlPolicy,\n\t\tstrict: input.strict,\n\t\tdefaultControlPolicy: input.contract.defaultControlPolicy,\n\t\tgranularityOf: input.granularityOf\n\t});\n\tconst storageTypeVerdict = computeStorageTypeVerdict({\n\t\tcontract: input.contract,\n\t\tnamespacePairs: verdictDiff.namespacePairs,\n\t\tcodecHooks: extractCodecControlHooks(input.frameworkComponents)\n\t});\n\tconst failCount = diffVerdict.failures.length + storageTypeVerdict.failures.length;\n\tconst ok = failCount === 0;\n\tconst profileHash = \"profileHash\" in input.contract && typeof input.contract.profileHash === \"string\" ? input.contract.profileHash : void 0;\n\treturn {\n\t\tok,\n\t\t...ok ? {} : { code: VERIFY_CODE_SCHEMA_FAILURE },\n\t\tsummary: ok ? \"Database schema satisfies contract\" : `Database schema does not satisfy contract (${failCount} failure${failCount === 1 ? \"\" : \"s\"})`,\n\t\tcontract: {\n\t\t\tstorageHash: input.contract.storage.storageHash,\n\t\t\t...ifDefined(\"profileHash\", profileHash)\n\t\t},\n\t\ttarget: {\n\t\t\texpected: input.contract.target,\n\t\t\tactual: input.contract.target\n\t\t},\n\t\tschema: {\n\t\t\tissues: [...diffVerdict.failures, ...storageTypeVerdict.failures],\n\t\t\twarnings: { issues: [...diffVerdict.warnings, ...storageTypeVerdict.warnings] }\n\t\t},\n\t\tmeta: { strict: input.strict },\n\t\ttimings: { total: Date.now() - startTime }\n\t};\n}\n//#endregion\nexport { computeStorageTypeVerdict as a, extractCodecControlHooks as c, computeSqlDiffVerdict as i, classifyDiffSubjectGranularity as n, verifySqlSchemaByDiff as o, classifySqlDiffIssue as r, enforceSqlDataTypeInvariants as s, classifyDiffEntityKind as t };\n\n//# sourceMappingURL=schema-verify-C3wbdviw.mjs.map"],"mappings":";;;;;;;;;;AAUA,SAAS,qBAAqB,YAAY;CACzC,IAAI,OAA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AAiB,MAAM,YAAY,OAAO,MAAM,SAAS,gBAAgB,WAAW,MAAM,SAAS,cAAc,KAAK;CAC1I,OAAO;EACN;EACA,GAAG,KAAK,CAAC,IAAI,EAAE,MAAM,2BAA2B;EAChD,SAAS,KAAK,uCAAuC,8CAA8C,UAAU,UAAU,cAAc,IAAI,KAAK,IAAI;EAClJ,UAAU;GACT,aAAa,MAAM,SAAS,QAAQ;GACpC,GAAG,UAAU,eAAe,WAAW;EACxC;EACA,QAAQ;GACP,UAAU,MAAM,SAAS;GACzB,QAAQ,MAAM,SAAS;EACxB;EACA,QAAQ;GACP,QAAQ,CAAC,GAAG,YAAY,UAAU,GAAG,mBAAmB,QAAQ;GAChE,UAAU,EAAE,QAAQ,CAAC,GAAG,YAAY,UAAU,GAAG,mBAAmB,QAAQ,EAAE;EAC/E;EACA,MAAM,EAAE,QAAQ,MAAM,OAAO;EAC7B,SAAS,EAAE,OAAO,KAAK,IAAI,IAAI,UAAU;CAC1C;AACD"}
|
package/dist/{serialized-index-52COq1yV-CUJ2F65u.mjs → serialized-index-DjCCnXB1-C_YccpTL.mjs}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { m as parseNaming } from "./naming-bM5qm5PY-DdginUhA.mjs";
|
|
2
|
-
import { o as SqlNode } from "./storage-table-
|
|
2
|
+
import { o as SqlNode } from "./storage-table-DDvN83mw-CbCFr5wm.mjs";
|
|
3
3
|
import { ContractValidationError } from "@prisma/orm-framework/contract/contract-validation-error";
|
|
4
4
|
import { freezeNode } from "@prisma/orm-framework/components/ir";
|
|
5
|
-
//#region ../../../2-sql/1-core/contract/dist/serialized-index-
|
|
5
|
+
//#region ../../../2-sql/1-core/contract/dist/serialized-index-DjCCnXB1.mjs
|
|
6
6
|
/**
|
|
7
7
|
* SQL Contract IR node for a value-set entry in a namespace's `valueSet`
|
|
8
8
|
* map (`SqlNamespace.entries.valueSet`).
|
|
@@ -71,4 +71,4 @@ function indexInputFromSerialized(flat) {
|
|
|
71
71
|
//#endregion
|
|
72
72
|
export { isStorageValueSet as i, checkConstraintInputFromSerialized as n, indexInputFromSerialized as r, StorageValueSet as t };
|
|
73
73
|
|
|
74
|
-
//# sourceMappingURL=serialized-index-
|
|
74
|
+
//# sourceMappingURL=serialized-index-DjCCnXB1-C_YccpTL.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"serialized-index-
|
|
1
|
+
{"version":3,"file":"serialized-index-DjCCnXB1-C_YccpTL.mjs","names":[],"sources":["../../../../2-sql/1-core/contract/dist/serialized-index-DjCCnXB1.mjs"],"sourcesContent":["import { l as SqlNode } from \"./storage-table-DDvN83mw.mjs\";\nimport { parseNaming } from \"@internal/sql-schema-ir/naming\";\nimport { freezeNode } from \"@internal/framework-components/ir\";\nimport { ContractValidationError } from \"@internal/contract/contract-validation-error\";\n//#region src/ir/storage-value-set.ts\n/**\n* SQL Contract IR node for a value-set entry in a namespace's `valueSet`\n* map (`SqlNamespace.entries.valueSet`).\n*\n* A value-set records the ordered set of permitted codec-encoded values for\n* an enum-like column restriction. It does not carry a `codecId` — the\n* column that references it already holds the codec; the value-set holds\n* only the permitted values.\n*\n* The node's `kind` is enumerable (`'valueSet'`) so the JSON envelope\n* carries the discriminator and the serializer hydration walker can\n* dispatch on it. This follows the per-leaf enumerable-kind convention\n* established in the SQL-node comment (future polymorphic dispatch on\n* namespace entries needs the discriminator in JSON).\n*\n* The entry's name is not on the class — value-sets are keyed by name in\n* the parent namespace's `valueSet: Record<string, StorageValueSet>` map.\n*/\nvar StorageValueSet = class extends SqlNode {\n\tkind = \"valueSet\";\n\tvalues;\n\tconstructor(input) {\n\t\tsuper();\n\t\tthis.values = Object.freeze([...input.values]);\n\t\tfreezeNode(this);\n\t}\n};\nfunction isStorageValueSet(value) {\n\tif (typeof value !== \"object\" || value === null) return false;\n\treturn \"kind\" in value && value.kind === \"valueSet\" && \"values\" in value;\n}\n//#endregion\n//#region src/serialized-check-constraint.ts\n/**\n* Hydrates one stored check constraint into constructor input. `parseNaming`\n* is what rejects a hand-edited file whose `prefix` and `name` disagree.\n*/\nfunction checkConstraintInputFromSerialized(flat) {\n\treturn {\n\t\tnaming: parseNaming(flat.name, flat.prefix),\n\t\texpression: flat.expression\n\t};\n}\n//#endregion\n//#region src/serialized-index.ts\n/**\n* Hydrates one stored index into constructor input. The parameter is typed\n* but the values are whatever the file held, so each field the union depends\n* on is checked here rather than downstream — by the time `Index` sees the\n* data it is already a valid union.\n*/\nfunction indexInputFromSerialized(flat) {\n\tif (flat.name === void 0 || flat.name.length === 0) throw new ContractValidationError(\"Index: every index carries a full physical name; an expression index must be explicitly named (a default name cannot be derived from an expression).\", \"storage\");\n\tif (flat.columns === void 0 === (flat.expression === void 0)) throw new ContractValidationError(`Index \"${flat.name}\": exactly one of columns or expression must be set.`, \"storage\");\n\tconst carried = {\n\t\tnaming: parseNaming(flat.name, flat.prefix),\n\t\twhere: flat.where,\n\t\tunique: flat.unique,\n\t\ttype: flat.type,\n\t\toptions: flat.options\n\t};\n\treturn flat.expression !== void 0 ? {\n\t\t...carried,\n\t\texpression: flat.expression\n\t} : {\n\t\t...carried,\n\t\tcolumns: flat.columns ?? []\n\t};\n}\n//#endregion\nexport { isStorageValueSet as i, checkConstraintInputFromSerialized as n, StorageValueSet as r, indexInputFromSerialized as t };\n\n//# sourceMappingURL=serialized-index-DjCCnXB1.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAuBA,IAAI,kBAAkB,cAAc,QAAQ;CAC3C,OAAO;CACP;CACA,YAAY,OAAO;EAClB,MAAM;EACN,KAAK,SAAS,OAAO,OAAO,CAAC,GAAG,MAAM,MAAM,CAAC;EAC7C,WAAW,IAAI;CAChB;AACD;AACA,SAAS,kBAAkB,OAAO;CACjC,IAAI,OAAO,UAAU,YAAY,UAAU,MAAM,OAAO;CACxD,OAAO,UAAU,SAAS,MAAM,SAAS,cAAc,YAAY;AACpE;;;;;AAOA,SAAS,mCAAmC,MAAM;CACjD,OAAO;EACN,QAAQ,YAAY,KAAK,MAAM,KAAK,MAAM;EAC1C,YAAY,KAAK;CAClB;AACD;;;;;;;AASA,SAAS,yBAAyB,MAAM;CACvC,IAAI,KAAK,SAAS,KAAK,KAAK,KAAK,KAAK,WAAW,GAAG,MAAM,IAAI,wBAAwB,wJAAwJ,SAAS;CACvP,IAAI,KAAK,YAAY,KAAK,OAAO,KAAK,eAAe,KAAK,IAAI,MAAM,IAAI,wBAAwB,UAAU,KAAK,KAAK,uDAAuD,SAAS;CACpL,MAAM,UAAU;EACf,QAAQ,YAAY,KAAK,MAAM,KAAK,MAAM;EAC1C,OAAO,KAAK;EACZ,QAAQ,KAAK;EACb,MAAM,KAAK;EACX,SAAS,KAAK;CACf;CACA,OAAO,KAAK,eAAe,KAAK,IAAI;EACnC,GAAG;EACH,YAAY,KAAK;CAClB,IAAI;EACH,GAAG;EACH,SAAS,KAAK,WAAW,CAAC;CAC3B;AACD"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as sqlContractCanonicalizationHooks } from "./canonicalization-hooks-dmXkOR4a.mjs";
|
|
2
|
-
import { f as composeSqlEntityKinds } from "./entity-kinds-
|
|
3
|
-
import { c as isMaterializedSqlNamespace, o as SqlStorage } from "./types-
|
|
4
|
-
import { f as validateSqlContractFully, i as createSqlContractSchema, s as resolveSqlToOneRelationStorage } from "./validators-
|
|
2
|
+
import { f as composeSqlEntityKinds } from "./entity-kinds-JR5SAm5h-ZkDejOUK.mjs";
|
|
3
|
+
import { c as isMaterializedSqlNamespace, o as SqlStorage } from "./types-C7610W2l.mjs";
|
|
4
|
+
import { f as validateSqlContractFully, i as createSqlContractSchema, s as resolveSqlToOneRelationStorage } from "./validators-xXKEHvnw.mjs";
|
|
5
5
|
import { t as sqlFamilyError } from "./errors-B5g0xWro-mWH2C07F.mjs";
|
|
6
6
|
import { ifDefined } from "@prisma/orm-framework/utils/defined";
|
|
7
7
|
import { ContractValidationError } from "@prisma/orm-framework/contract/contract-validation-error";
|
|
@@ -193,4 +193,4 @@ var SqlContractSerializer = class extends SqlContractSerializerBase {
|
|
|
193
193
|
//#endregion
|
|
194
194
|
export { SqlContractSerializerBase as n, SqlContractSerializer as t };
|
|
195
195
|
|
|
196
|
-
//# sourceMappingURL=sql-contract-serializer-sMY3prTx-
|
|
196
|
+
//# sourceMappingURL=sql-contract-serializer-sMY3prTx-BkFoHhST.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sql-contract-serializer-sMY3prTx-CpZa5Nlt.mjs","names":[],"sources":["../../../../2-sql/9-family/dist/sql-contract-serializer-sMY3prTx.mjs"],"sourcesContent":["import { t as sqlFamilyError } from \"./errors-B5g0xWro.mjs\";\nimport { hydrateNamespaceEntities } from \"@internal/framework-components/ir\";\nimport { sqlContractCanonicalizationHooks } from \"@internal/sql-contract/canonicalization-hooks\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { ifDefined } from \"@internal/utils/defined\";\nimport { ContractValidationError } from \"@internal/contract/contract-validation-error\";\nimport { SqlStorage, isMaterializedSqlNamespace } from \"@internal/sql-contract/types\";\nimport { createSqlContractSchema, resolveSqlToOneRelationStorage, validateSqlContractFully } from \"@internal/sql-contract/validators\";\nimport { isPlainRecord as isPlainRecord$1 } from \"@internal/contract/is-plain-record\";\nimport { withDerivedToOneRelationNullability } from \"@internal/contract-authoring\";\nimport { composeSqlEntityKinds } from \"@internal/sql-contract/entity-kinds\";\nimport { type } from \"arktype\";\n//#region src/core/ir/sql-contract-serializer-base.ts\nconst NamespaceRawSchema = type({\n\tid: \"string\",\n\t\"kind?\": \"string\",\n\tentries: type({ \"+\": \"ignore\" })\n});\n/**\n* A `contract.json` written before to-one relations recorded `nullable` (rc.9 and earlier)\n* loads with the flag derived from storage: nullable when any local FK column is nullable or\n* cannot be resolved.\n*/\nfunction withSqlToOneRelationNullability(contract) {\n\tconst domain = withDerivedToOneRelationNullability(contract.domain, ({ model, relation }) => {\n\t\tconst { ownsForeignKey, columns } = resolveSqlToOneRelationStorage(contract, blindCast(model.storage), relation);\n\t\treturn {\n\t\t\townsReference: ownsForeignKey,\n\t\t\tlocalFieldNullability: columns.map((column) => column.nullable)\n\t\t};\n\t});\n\treturn {\n\t\t...contract,\n\t\tdomain\n\t};\n}\n/**\n* SQL family `ContractSerializer` abstract base. Carries the SQL-shared\n* deserialization pipeline:\n*\n* 1. `parseSqlContractStructure` validates the on-disk JSON envelope\n* against the SQL contract arktype schema (`validateSqlContractFully`)\n* and returns the validated flat-data shape.\n* 2. `hydrateSqlStorage` walks the validated `storage` subtree and\n* constructs the family-shared SQL Contract IR class hierarchy\n* (`SqlStorage` -> `StorageTable` -> `StorageColumn` / `PrimaryKey`\n* / …). The rest of the contract envelope is JSON-clean primitive\n* data and passes through unchanged.\n* 3. `constructTargetContract` is the target-specific extension hook;\n* defaults to identity. Targets that need to attach target-only\n* fields (e.g. target-specific derived storage fields) override it.\n*\n* Default `serializeContract` is identity over the contract — concrete\n* SQL targets ship JSON-clean class instances, so the contract value\n* can be stringified directly. The non-enumerable family-level `kind`\n* discriminator on `SqlNode` instances stays out of the persisted\n* envelope automatically. Targets that need to canonicalize on the way\n* out (key ordering, dropping computed-only fields) override\n* `serializeContract` directly.\n*/\nvar SqlContractSerializerBase = class {\n\tentityHydrationRegistry;\n\tdataTypes;\n\tcontractSchema;\n\tentryKinds;\n\tconstructor(entityHydrationRegistry = /* @__PURE__ */ new Map(), packEntityKinds = [], dataTypes = void 0) {\n\t\tthis.entityHydrationRegistry = entityHydrationRegistry;\n\t\tthis.dataTypes = dataTypes;\n\t\tthis.entryKinds = composeSqlEntityKinds(packEntityKinds);\n\t\tthis.contractSchema = packEntityKinds.length > 0 ? createSqlContractSchema(this.entryKinds) : void 0;\n\t}\n\tdeserializeContract(json) {\n\t\tconst validated = withSqlToOneRelationNullability(this.parseSqlContractStructure(json));\n\t\tconst hydrated = this.hydrateSqlStorage(validated);\n\t\treturn blindCast(this.constructTargetContract(hydrated));\n\t}\n\tserializeContract(contract) {\n\t\treturn blindCast(contract);\n\t}\n\tshouldPreserveEmpty = sqlContractCanonicalizationHooks.shouldPreserveEmpty;\n\tsortStorage = sqlContractCanonicalizationHooks.sortStorage;\n\thashCanonicalizationHooks = sqlContractCanonicalizationHooks;\n\tparseSqlContractStructure(json) {\n\t\treturn validateSqlContractFully(json, {\n\t\t\t...ifDefined(\"contractSchema\", this.contractSchema),\n\t\t\t...ifDefined(\"dataTypes\", this.dataTypes)\n\t\t});\n\t}\n\thydrateSqlStorage(validated) {\n\t\tconst types = validated.storage.types;\n\t\tconst hydratedTypes = types !== void 0 ? Object.fromEntries(Object.entries(types).map(([name, entry]) => [name, this.hydrateStorageTypeEntry(entry)])) : void 0;\n\t\tconst rawNamespaces = validated.storage.namespaces;\n\t\tif (rawNamespaces === void 0) throw new ContractValidationError(\"Contract storage.namespaces is required after structural validation\", \"structural\");\n\t\tconst hydratedNamespaces = this.hydrateSqlNamespaceMap(blindCast(rawNamespaces));\n\t\treturn {\n\t\t\t...validated,\n\t\t\tstorage: new SqlStorage({\n\t\t\t\tstorageHash: validated.storage.storageHash,\n\t\t\t\t...ifDefined(\"types\", hydratedTypes),\n\t\t\t\tnamespaces: blindCast(hydratedNamespaces)\n\t\t\t})\n\t\t};\n\t}\n\thydrateSqlNamespaceMap(namespaces) {\n\t\treturn Object.fromEntries(Object.entries(namespaces).map(([nsId, namespaceEntryRaw]) => {\n\t\t\tconst namespaceHydrated = this.hydrateSqlNamespaceEntry(nsId, namespaceEntryRaw);\n\t\t\tif (!isMaterializedSqlNamespace(namespaceHydrated)) throw sqlFamilyError(\"CONTRACT.PACK_CONTRIBUTION_INVALID\", `Target serializer bug: hydrateSqlNamespaceEntry for namespace \"${nsId}\" returned a non-NamespaceBase value. Override hydrateSqlNamespaceEntry to produce a target namespace concretion.`, {\n\t\t\t\twhy: \"The target contract serializer hydrated a namespace into a value that is not a materialized namespace concretion.\",\n\t\t\t\tfix: \"Fix the target package: its hydrateSqlNamespaceEntry override must return a target namespace concretion.\",\n\t\t\t\tmeta: { namespaceId: nsId }\n\t\t\t});\n\t\t\treturn [nsId, namespaceHydrated];\n\t\t}));\n\t}\n\thydrateSqlNamespaceEntry(nsId, raw) {\n\t\tconst id = typeof raw[\"id\"] === \"string\" ? raw[\"id\"] : nsId;\n\t\tconst parsed = NamespaceRawSchema({\n\t\t\t...raw,\n\t\t\tid\n\t\t});\n\t\tif (parsed instanceof type.errors) throw new ContractValidationError(`Namespace hydration failed: ${parsed.map((p) => p.message).join(\"; \")}`, \"structural\");\n\t\tconst entriesRaw = parsed.entries;\n\t\tconst rawEntriesMap = isPlainRecord$1(entriesRaw) ? entriesRaw : {};\n\t\tconst entriesInput = {};\n\t\tfor (const [key, innerMap] of Object.entries(rawEntriesMap)) entriesInput[key] = isPlainRecord$1(innerMap) ? innerMap : Object.freeze({});\n\t\tconst entriesOutput = hydrateNamespaceEntities(entriesInput, this.entryKinds, \"fail\", id);\n\t\tif (!Object.hasOwn(entriesOutput, \"table\")) entriesOutput[\"table\"] = {};\n\t\treturn blindCast({\n\t\t\tid,\n\t\t\tentries: entriesOutput\n\t\t});\n\t}\n\thydrateStorageTypeEntry(entry) {\n\t\tif (typeof entry !== \"object\" || entry === null) return entry;\n\t\tconst kind = isPlainRecord$1(entry) && \"kind\" in entry ? entry.kind : void 0;\n\t\tif (typeof kind !== \"string\") return entry;\n\t\tconst factory = this.entityHydrationRegistry.get(kind);\n\t\tif (factory === void 0) return entry;\n\t\treturn blindCast(factory(entry));\n\t}\n\tconstructTargetContract(hydrated) {\n\t\treturn blindCast(hydrated);\n\t}\n\t/**\n\t* Serializes a namespace's `entries` dict by walking every enumerable\n\t* kind — no kind is named here, mirroring the generic hydrate walk in\n\t* `hydrateSqlNamespaceEntry` above. `table` is the SQL family's one\n\t* universal base kind (every namespace carries it), so it is always\n\t* emitted, even when empty; every other kind — target- or\n\t* pack-contributed — is emitted only when it holds at least one entry.\n\t* A kind carried non-enumerable on `entries` is excluded here for free,\n\t* since `Object.entries` honors enumerability.\n\t*/\n\tserializeNamespaceEntries(entries) {\n\t\tconst out = { table: this.serializeEntries(entries[\"table\"] ?? {}) };\n\t\tfor (const [kind, record] of Object.entries(entries)) {\n\t\t\tif (kind === \"table\" || record == null || Object.keys(record).length === 0) continue;\n\t\t\tout[kind] = this.serializeEntries(record);\n\t\t}\n\t\treturn out;\n\t}\n\tserializeEntries(entries) {\n\t\tconst out = {};\n\t\tfor (const [name, entry] of Object.entries(entries)) out[name] = this.serializeJsonObject(entry);\n\t\treturn out;\n\t}\n\tserializeJsonObject(value) {\n\t\treturn blindCast(this.serializeJsonValue(value));\n\t}\n\tserializeJsonValue(value) {\n\t\treturn blindCast(JSON.parse(JSON.stringify(value)));\n\t}\n};\n//#endregion\n//#region src/core/ir/sql-contract-serializer.ts\n/**\n* Default SQL family `ContractSerializer` concretion. Inherits the\n* full SQL-shared deserialization pipeline (structural validation +\n* IR-class hydration) without pack-registered `storage.types`\n* hydration factories — targets that emit polymorphic JSON outside the\n* codec-typed envelope wire a target-specific subclass with a populated\n* registry (see Postgres). Family-level call sites instantiate this\n* default directly when no target serializer is supplied.\n*\n* Because this serializer has no target concretion, deserialization of\n* contracts that include namespace entries from JSON will throw unless\n* the caller provides pre-hydrated `NamespaceBase` instances. Production\n* paths always supply a target-specific serializer.\n*/\nvar SqlContractSerializer = class extends SqlContractSerializerBase {\n\tconstructor() {\n\t\tsuper(/* @__PURE__ */ new Map());\n\t}\n};\n//#endregion\nexport { SqlContractSerializerBase as n, SqlContractSerializer as t };\n\n//# sourceMappingURL=sql-contract-serializer-sMY3prTx.mjs.map"],"mappings":";;;;;;;;;;;;;AAaA,MAAM,qBAAqB,KAAK;CAC/B,IAAI;CACJ,SAAS;CACT,SAAS,KAAK,EAAE,KAAK,SAAS,CAAC;AAChC,CAAC;;;;;;AAMD,SAAS,gCAAgC,UAAU;CAClD,MAAM,SAAS,oCAAoC,SAAS,SAAS,EAAE,OAAO,eAAe;EAC5F,MAAM,EAAE,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AwB,OAAO;EAC9B,IAAI,OAAO,UAAU,YAAY,UAAU,MAAM,OAAO;EACxD,MAAM,OAAO,gBAAgB,KAAK,KAAK,UAAU,QAAQ,MAAM,OAAO,KAAK;EAC3E,IAAI,OAAO,SAAS,UAAU,OAAO;EACrC,MAAM,UAAU,KAAK,wBAAwB,IAAI,IAAI;EACrD,IAAI,YAAY,KAAK,GAAG,OAAO;EAC/B,OAAO,UAAU,QAAQ,KAAK,CAAC;CAChC;CACA,wBAAwB,UAAU;EACjC,OAAO,UAAU,QAAQ;CAC1B;;;;;;;;;;;CAWA,0BAA0B,SAAS;EAClC,MAAM,MAAM,EAAE,OAAO,KAAK,iBAAiB,QAAQ,YAAY,CAAC,CAAC,EAAE;EACnE,KAAK,MAAM,CAAC,MAAM,WAAW,OAAO,QAAQ,OAAO,GAAG;GACrD,IAAI,SAAS,WAAW,UAAU,QAAQ,OAAO,KAAK,MAAM,CAAC,CAAC,WAAW,GAAG;GAC5E,IAAI,QAAQ,KAAK,iBAAiB,MAAM;EACzC;EACA,OAAO;CACR;CACA,iBAAiB,SAAS;EACzB,MAAM,MAAM,CAAC;EACb,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAQ,OAAO,GAAG,IAAI,QAAQ,KAAK,oBAAoB,KAAK;EAC/F,OAAO;CACR;CACA,oBAAoB,OAAO;EAC1B,OAAO,UAAU,KAAK,mBAAmB,KAAK,CAAC;CAChD;CACA,mBAAmB,OAAO;EACzB,OAAO,UAAU,KAAK,MAAM,KAAK,UAAU,KAAK,CAAC,CAAC;CACnD;AACD;;;;;;;;;;;;;;;AAiBA,IAAI,wBAAwB,cAAc,0BAA0B;CACnE,cAAc;EACb,sBAAsB,IAAI,IAAI,CAAC;CAChC;AACD"}
|
|
1
|
+
{"version":3,"file":"sql-contract-serializer-sMY3prTx-BkFoHhST.mjs","names":[],"sources":["../../../../2-sql/9-family/dist/sql-contract-serializer-sMY3prTx.mjs"],"sourcesContent":["import { t as sqlFamilyError } from \"./errors-B5g0xWro.mjs\";\nimport { hydrateNamespaceEntities } from \"@internal/framework-components/ir\";\nimport { sqlContractCanonicalizationHooks } from \"@internal/sql-contract/canonicalization-hooks\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { ifDefined } from \"@internal/utils/defined\";\nimport { ContractValidationError } from \"@internal/contract/contract-validation-error\";\nimport { SqlStorage, isMaterializedSqlNamespace } from \"@internal/sql-contract/types\";\nimport { createSqlContractSchema, resolveSqlToOneRelationStorage, validateSqlContractFully } from \"@internal/sql-contract/validators\";\nimport { isPlainRecord as isPlainRecord$1 } from \"@internal/contract/is-plain-record\";\nimport { withDerivedToOneRelationNullability } from \"@internal/contract-authoring\";\nimport { composeSqlEntityKinds } from \"@internal/sql-contract/entity-kinds\";\nimport { type } from \"arktype\";\n//#region src/core/ir/sql-contract-serializer-base.ts\nconst NamespaceRawSchema = type({\n\tid: \"string\",\n\t\"kind?\": \"string\",\n\tentries: type({ \"+\": \"ignore\" })\n});\n/**\n* A `contract.json` written before to-one relations recorded `nullable` (rc.9 and earlier)\n* loads with the flag derived from storage: nullable when any local FK column is nullable or\n* cannot be resolved.\n*/\nfunction withSqlToOneRelationNullability(contract) {\n\tconst domain = withDerivedToOneRelationNullability(contract.domain, ({ model, relation }) => {\n\t\tconst { ownsForeignKey, columns } = resolveSqlToOneRelationStorage(contract, blindCast(model.storage), relation);\n\t\treturn {\n\t\t\townsReference: ownsForeignKey,\n\t\t\tlocalFieldNullability: columns.map((column) => column.nullable)\n\t\t};\n\t});\n\treturn {\n\t\t...contract,\n\t\tdomain\n\t};\n}\n/**\n* SQL family `ContractSerializer` abstract base. Carries the SQL-shared\n* deserialization pipeline:\n*\n* 1. `parseSqlContractStructure` validates the on-disk JSON envelope\n* against the SQL contract arktype schema (`validateSqlContractFully`)\n* and returns the validated flat-data shape.\n* 2. `hydrateSqlStorage` walks the validated `storage` subtree and\n* constructs the family-shared SQL Contract IR class hierarchy\n* (`SqlStorage` -> `StorageTable` -> `StorageColumn` / `PrimaryKey`\n* / …). The rest of the contract envelope is JSON-clean primitive\n* data and passes through unchanged.\n* 3. `constructTargetContract` is the target-specific extension hook;\n* defaults to identity. Targets that need to attach target-only\n* fields (e.g. target-specific derived storage fields) override it.\n*\n* Default `serializeContract` is identity over the contract — concrete\n* SQL targets ship JSON-clean class instances, so the contract value\n* can be stringified directly. The non-enumerable family-level `kind`\n* discriminator on `SqlNode` instances stays out of the persisted\n* envelope automatically. Targets that need to canonicalize on the way\n* out (key ordering, dropping computed-only fields) override\n* `serializeContract` directly.\n*/\nvar SqlContractSerializerBase = class {\n\tentityHydrationRegistry;\n\tdataTypes;\n\tcontractSchema;\n\tentryKinds;\n\tconstructor(entityHydrationRegistry = /* @__PURE__ */ new Map(), packEntityKinds = [], dataTypes = void 0) {\n\t\tthis.entityHydrationRegistry = entityHydrationRegistry;\n\t\tthis.dataTypes = dataTypes;\n\t\tthis.entryKinds = composeSqlEntityKinds(packEntityKinds);\n\t\tthis.contractSchema = packEntityKinds.length > 0 ? createSqlContractSchema(this.entryKinds) : void 0;\n\t}\n\tdeserializeContract(json) {\n\t\tconst validated = withSqlToOneRelationNullability(this.parseSqlContractStructure(json));\n\t\tconst hydrated = this.hydrateSqlStorage(validated);\n\t\treturn blindCast(this.constructTargetContract(hydrated));\n\t}\n\tserializeContract(contract) {\n\t\treturn blindCast(contract);\n\t}\n\tshouldPreserveEmpty = sqlContractCanonicalizationHooks.shouldPreserveEmpty;\n\tsortStorage = sqlContractCanonicalizationHooks.sortStorage;\n\thashCanonicalizationHooks = sqlContractCanonicalizationHooks;\n\tparseSqlContractStructure(json) {\n\t\treturn validateSqlContractFully(json, {\n\t\t\t...ifDefined(\"contractSchema\", this.contractSchema),\n\t\t\t...ifDefined(\"dataTypes\", this.dataTypes)\n\t\t});\n\t}\n\thydrateSqlStorage(validated) {\n\t\tconst types = validated.storage.types;\n\t\tconst hydratedTypes = types !== void 0 ? Object.fromEntries(Object.entries(types).map(([name, entry]) => [name, this.hydrateStorageTypeEntry(entry)])) : void 0;\n\t\tconst rawNamespaces = validated.storage.namespaces;\n\t\tif (rawNamespaces === void 0) throw new ContractValidationError(\"Contract storage.namespaces is required after structural validation\", \"structural\");\n\t\tconst hydratedNamespaces = this.hydrateSqlNamespaceMap(blindCast(rawNamespaces));\n\t\treturn {\n\t\t\t...validated,\n\t\t\tstorage: new SqlStorage({\n\t\t\t\tstorageHash: validated.storage.storageHash,\n\t\t\t\t...ifDefined(\"types\", hydratedTypes),\n\t\t\t\tnamespaces: blindCast(hydratedNamespaces)\n\t\t\t})\n\t\t};\n\t}\n\thydrateSqlNamespaceMap(namespaces) {\n\t\treturn Object.fromEntries(Object.entries(namespaces).map(([nsId, namespaceEntryRaw]) => {\n\t\t\tconst namespaceHydrated = this.hydrateSqlNamespaceEntry(nsId, namespaceEntryRaw);\n\t\t\tif (!isMaterializedSqlNamespace(namespaceHydrated)) throw sqlFamilyError(\"CONTRACT.PACK_CONTRIBUTION_INVALID\", `Target serializer bug: hydrateSqlNamespaceEntry for namespace \"${nsId}\" returned a non-NamespaceBase value. Override hydrateSqlNamespaceEntry to produce a target namespace concretion.`, {\n\t\t\t\twhy: \"The target contract serializer hydrated a namespace into a value that is not a materialized namespace concretion.\",\n\t\t\t\tfix: \"Fix the target package: its hydrateSqlNamespaceEntry override must return a target namespace concretion.\",\n\t\t\t\tmeta: { namespaceId: nsId }\n\t\t\t});\n\t\t\treturn [nsId, namespaceHydrated];\n\t\t}));\n\t}\n\thydrateSqlNamespaceEntry(nsId, raw) {\n\t\tconst id = typeof raw[\"id\"] === \"string\" ? raw[\"id\"] : nsId;\n\t\tconst parsed = NamespaceRawSchema({\n\t\t\t...raw,\n\t\t\tid\n\t\t});\n\t\tif (parsed instanceof type.errors) throw new ContractValidationError(`Namespace hydration failed: ${parsed.map((p) => p.message).join(\"; \")}`, \"structural\");\n\t\tconst entriesRaw = parsed.entries;\n\t\tconst rawEntriesMap = isPlainRecord$1(entriesRaw) ? entriesRaw : {};\n\t\tconst entriesInput = {};\n\t\tfor (const [key, innerMap] of Object.entries(rawEntriesMap)) entriesInput[key] = isPlainRecord$1(innerMap) ? innerMap : Object.freeze({});\n\t\tconst entriesOutput = hydrateNamespaceEntities(entriesInput, this.entryKinds, \"fail\", id);\n\t\tif (!Object.hasOwn(entriesOutput, \"table\")) entriesOutput[\"table\"] = {};\n\t\treturn blindCast({\n\t\t\tid,\n\t\t\tentries: entriesOutput\n\t\t});\n\t}\n\thydrateStorageTypeEntry(entry) {\n\t\tif (typeof entry !== \"object\" || entry === null) return entry;\n\t\tconst kind = isPlainRecord$1(entry) && \"kind\" in entry ? entry.kind : void 0;\n\t\tif (typeof kind !== \"string\") return entry;\n\t\tconst factory = this.entityHydrationRegistry.get(kind);\n\t\tif (factory === void 0) return entry;\n\t\treturn blindCast(factory(entry));\n\t}\n\tconstructTargetContract(hydrated) {\n\t\treturn blindCast(hydrated);\n\t}\n\t/**\n\t* Serializes a namespace's `entries` dict by walking every enumerable\n\t* kind — no kind is named here, mirroring the generic hydrate walk in\n\t* `hydrateSqlNamespaceEntry` above. `table` is the SQL family's one\n\t* universal base kind (every namespace carries it), so it is always\n\t* emitted, even when empty; every other kind — target- or\n\t* pack-contributed — is emitted only when it holds at least one entry.\n\t* A kind carried non-enumerable on `entries` is excluded here for free,\n\t* since `Object.entries` honors enumerability.\n\t*/\n\tserializeNamespaceEntries(entries) {\n\t\tconst out = { table: this.serializeEntries(entries[\"table\"] ?? {}) };\n\t\tfor (const [kind, record] of Object.entries(entries)) {\n\t\t\tif (kind === \"table\" || record == null || Object.keys(record).length === 0) continue;\n\t\t\tout[kind] = this.serializeEntries(record);\n\t\t}\n\t\treturn out;\n\t}\n\tserializeEntries(entries) {\n\t\tconst out = {};\n\t\tfor (const [name, entry] of Object.entries(entries)) out[name] = this.serializeJsonObject(entry);\n\t\treturn out;\n\t}\n\tserializeJsonObject(value) {\n\t\treturn blindCast(this.serializeJsonValue(value));\n\t}\n\tserializeJsonValue(value) {\n\t\treturn blindCast(JSON.parse(JSON.stringify(value)));\n\t}\n};\n//#endregion\n//#region src/core/ir/sql-contract-serializer.ts\n/**\n* Default SQL family `ContractSerializer` concretion. Inherits the\n* full SQL-shared deserialization pipeline (structural validation +\n* IR-class hydration) without pack-registered `storage.types`\n* hydration factories — targets that emit polymorphic JSON outside the\n* codec-typed envelope wire a target-specific subclass with a populated\n* registry (see Postgres). Family-level call sites instantiate this\n* default directly when no target serializer is supplied.\n*\n* Because this serializer has no target concretion, deserialization of\n* contracts that include namespace entries from JSON will throw unless\n* the caller provides pre-hydrated `NamespaceBase` instances. Production\n* paths always supply a target-specific serializer.\n*/\nvar SqlContractSerializer = class extends SqlContractSerializerBase {\n\tconstructor() {\n\t\tsuper(/* @__PURE__ */ new Map());\n\t}\n};\n//#endregion\nexport { SqlContractSerializerBase as n, SqlContractSerializer as t };\n\n//# sourceMappingURL=sql-contract-serializer-sMY3prTx.mjs.map"],"mappings":";;;;;;;;;;;;;AAaA,MAAM,qBAAqB,KAAK;CAC/B,IAAI;CACJ,SAAS;CACT,SAAS,KAAK,EAAE,KAAK,SAAS,CAAC;AAChC,CAAC;;;;;;AAMD,SAAS,gCAAgC,UAAU;CAClD,MAAM,SAAS,oCAAoC,SAAS,SAAS,EAAE,OAAO,eAAe;EAC5F,MAAM,EAAE,gBAAgB,YAAY,+BAA+B,UAAU,UAAU,MAAM,OAAO,GAAG,QAAQ;EAC/G,OAAO;GACN,eAAe;GACf,uBAAuB,QAAQ,KAAK,WAAW,OAAO,QAAQ;EAC/D;CACD,CAAC;CACD,OAAO;EACN,GAAG;EACH;CACD;AACD;;;;;;;;;;;;;;;;;;;;;;;;;AAyBA,IAAI,4BAA4B,MAAM;CACrC;CACA;CACA;CACA;CACA,YAAY,0CAA0C,IAAI,IAAI,GAAG,kBAAkB,CAAC,GAAG,YAAY,KAAK,GAAG;EAC1G,KAAK,0BAA0B;EAC/B,KAAK,YAAY;EACjB,KAAK,aAAa,sBAAsB,eAAe;EACvD,KAAK,iBA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,YAAY,CAAC,CAAC,EAAE;EACnE,KAAK,MAAM,CAAC,MAAM,WAAW,OAAO,QAAQ,OAAO,GAAG;GACrD,IAAI,SAAS,WAAW,UAAU,QAAQ,OAAO,KAAK,MAAM,CAAC,CAAC,WAAW,GAAG;GAC5E,IAAI,QAAQ,KAAK,iBAAiB,MAAM;EACzC;EACA,OAAO;CACR;CACA,iBAAiB,SAAS;EACzB,MAAM,MAAM,CAAC;EACb,KAAK,MAAM,CAAC,MAAM,UAAU,OAAO,QAAQ,OAAO,GAAG,IAAI,QAAQ,KAAK,oBAAoB,KAAK;EAC/F,OAAO;CACR;CACA,oBAAoB,OAAO;EAC1B,OAAO,UAAU,KAAK,mBAAmB,KAAK,CAAC;CAChD;CACA,mBAAmB,OAAO;EACzB,OAAO,UAAU,KAAK,MAAM,KAAK,UAAU,KAAK,CAAC,CAAC;CACnD;AACD;;;;;;;;;;;;;;;AAiBA,IAAI,wBAAwB,cAAc,0BAA0B;CACnE,cAAc;EACb,sBAAsB,IAAI,IAAI,CAAC;CAChC;AACD"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { h as AnyQueryAst } from "./types-
|
|
1
|
+
import { h as AnyQueryAst } from "./types-DriMIMNQ-BBacSgaI.mjs";
|
|
2
2
|
import { ExecutionPlan } from "@prisma/orm-framework/components/runtime";
|
|
3
|
-
//#region ../../../2-sql/4-lanes/relational-core/dist/sql-execution-plan-
|
|
3
|
+
//#region ../../../2-sql/4-lanes/relational-core/dist/sql-execution-plan-3uxYjHyu.d.mts
|
|
4
4
|
//#region src/sql-execution-plan.d.ts
|
|
5
5
|
/**
|
|
6
6
|
* SQL-domain execution plan: a query lowered to the wire-level shape that a
|
|
@@ -28,4 +28,4 @@ interface SqlExecutionPlan<Row = unknown> extends ExecutionPlan<Row> {
|
|
|
28
28
|
}
|
|
29
29
|
//#endregion
|
|
30
30
|
export { SqlExecutionPlan as t };
|
|
31
|
-
//# sourceMappingURL=sql-execution-plan-
|
|
31
|
+
//# sourceMappingURL=sql-execution-plan-3uxYjHyu-C0Z4_RSY.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sql-execution-plan-3uxYjHyu-C0Z4_RSY.d.mts","names":[],"sources":["../../../../2-sql/4-lanes/relational-core/dist/sql-execution-plan-3uxYjHyu.d.mts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;UAsBU,iBAAiB,uBAAuB,cAAc;WACrD;WACA;WACA,KAAK"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { t as SqlNode } from "./sql-node-kEz6YFZo-v2F7delx.mjs";
|
|
2
|
-
import { r as StorageTable } from "./storage-table-
|
|
2
|
+
import { r as StorageTable } from "./storage-table-Bf1ZjnxO-NvkG2pgq.mjs";
|
|
3
3
|
import { t as StorageValueSet } from "./storage-value-set-BGlj5Uus-CvZD--GG.mjs";
|
|
4
4
|
import { AuthoringContributions } from "@prisma/orm-framework/components/authoring";
|
|
5
5
|
import { Namespace, NamespaceBase, Storage, StorageType } from "@prisma/orm-framework/components/ir";
|
|
6
6
|
import { StorageHashBase } from "@prisma/orm-framework/contract/types";
|
|
7
|
-
//#region ../../../2-sql/1-core/contract/dist/sql-storage-
|
|
7
|
+
//#region ../../../2-sql/1-core/contract/dist/sql-storage-DeCAh5Hi.d.mts
|
|
8
8
|
//#region src/ir/storage-type-instance.d.ts
|
|
9
9
|
/**
|
|
10
10
|
* Sentinel kind for the legacy codec-triple shape persisted under
|
|
@@ -40,12 +40,9 @@ type StorageTypeInstanceInput = Omit<StorageTypeInstance, 'kind' | 'typeParams'>
|
|
|
40
40
|
*/
|
|
41
41
|
declare function toStorageTypeInstance(input: StorageTypeInstanceInput): StorageTypeInstance;
|
|
42
42
|
/**
|
|
43
|
-
*
|
|
43
|
+
* A type's parameters, with empty parameters read as none, as a codec reads them; {@link toStorageTypeInstance} stores `{}` for a codec without parameters.
|
|
44
44
|
*/
|
|
45
|
-
declare function
|
|
46
|
-
readonly typeParams?: Record<string, unknown> | undefined;
|
|
47
|
-
readonly typeRef?: string | undefined;
|
|
48
|
-
}, namedTypes: Readonly<Record<string, Pick<StorageTypeInstanceInput, 'typeParams'>>> | undefined): Record<string, unknown> | undefined;
|
|
45
|
+
declare function nonEmptyTypeParams(typeParams: Record<string, unknown> | undefined): Record<string, unknown> | undefined;
|
|
49
46
|
/**
|
|
50
47
|
* Type-guard for codec-typed entries on the polymorphic
|
|
51
48
|
* `SqlStorage.types` slot. Distinguishes `StorageTypeInstance` from
|
|
@@ -167,5 +164,5 @@ declare class SqlStorage<THash extends string = string> extends SqlNode implemen
|
|
|
167
164
|
constructor(input: SqlStorageInput<THash>);
|
|
168
165
|
}
|
|
169
166
|
//#endregion
|
|
170
|
-
export {
|
|
171
|
-
//# sourceMappingURL=sql-storage-
|
|
167
|
+
export { nonEmptyTypeParams as _, SqlNamespaceBase as a, SqlNamespaceInput as c, SqlStorageTypeEntry as d, StorageTypeInstance as f, isStorageTypeInstance as g, isSqlAuthoringContributions as h, SqlNamespace as i, SqlStorage as l, isMaterializedSqlNamespace as m, CODEC_INSTANCE_KIND as n, SqlNamespaceEntries as o, StorageTypeInstanceInput as p, SqlAuthoringContributions as r, SqlNamespaceFactory as s, AuthoredStorageTypeInstance as t, SqlStorageInput as u, toStorageTypeInstance as v };
|
|
168
|
+
//# sourceMappingURL=sql-storage-DeCAh5Hi-nJQUIgfL.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sql-storage-DeCAh5Hi-nJQUIgfL.d.mts","names":[],"sources":["../../../../2-sql/1-core/contract/dist/sql-storage-DeCAh5Hi.d.mts"],"mappings":";;;;;;;;;;;;;;;cAcc;;;;UAIJ,4BAA4B;WAC3B,aAAa;WACb;WACA;WACA,YAAY;;;;;KAKlB,8BAA8B,KAAK;;;;KAInC,2BAA2B,KAAK;WAC1B,aAAa;;;;;;;iBAOP,sBAAsB,OAAO,2BAA2B;;;;iBAIxD,mBAAmB,YAAY,sCAAsC;;;;;;iBAMrE,sBAAsB,iBAAiB,SAAS;;;;;;;;;;KAU5D,sBAAsB,sBAAsB;UACvC;WACC;WACA,SAAS,SAAS,eAAe,SAAS;;;;;;KAMhD,uBAAuB,OAAO,sBAAsB;;;;;;;;UAQ/C,kCAAkC;WACjC,kBAAkB;;;;;;iBAMZ,4BAA4B,WAAW,qCAAqC,aAAa;UAChG,gBAAgB;WACf,aAAa,gBAAgB;WAC7B,QAAQ,eAAe;WACvB,YAAY,SAAS,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA6B1C,sBAAsB,SAAS,eAAe,SAAS;WACjD,QAAQ,SAAS,eAAe;WAChC,WAAW,SAAS,eAAe;;;;;;;;;;;UAWpC;WACC;WACA;WACA,SAAS;WACT;EACT,cAAc;;;;;;;;uBAQO,yBAAyB,yBAAyB;oBACrD;oBACA,SAAS;WAClB,aAAa;;;;;;;;;;;;iBAYP,2BAA2B,aAAa,KAAK;cAChD,WAAW,uCAAuC,mBAAmB;WACxE,aAAa,gBAAgB;WAC7B,YAAY,SAAS,eAAe;WACpC,QAAQ,SAAS,eAAe;EACzC,YAAY,OAAO,gBAAgB"}
|
package/dist/{storage-table-DC9afJhr-CmRU56OS.d.mts → storage-table-Bf1ZjnxO-NvkG2pgq.d.mts}
RENAMED
|
@@ -4,17 +4,13 @@ import { r as ForeignKeyInput, t as ForeignKey } from "./foreign-key-qkDFfG8t-Fy
|
|
|
4
4
|
import { i as UniqueConstraintInput, n as PrimaryKeyInput, r as UniqueConstraint, t as PrimaryKey } from "./unique-constraint-M5TlQnJQ-BiIHJ85k.mjs";
|
|
5
5
|
import { r as IndexInput, t as Index } from "./sql-index-ByAAE7K8-BpbPBWPD.mjs";
|
|
6
6
|
import { ColumnDefault, ControlPolicy, ValueSetRef } from "@prisma/orm-framework/contract/types";
|
|
7
|
-
//#region ../../../2-sql/1-core/contract/dist/storage-table-
|
|
7
|
+
//#region ../../../2-sql/1-core/contract/dist/storage-table-Bf1ZjnxO.d.mts
|
|
8
8
|
//#region src/ir/storage-column.d.ts
|
|
9
9
|
/**
|
|
10
10
|
* Hydration / construction input shape for {@link StorageColumn}. Mirrors
|
|
11
11
|
* the on-disk storage JSON envelope exactly so the family-base
|
|
12
12
|
* serializer's hydration walker can hand an arktype-validated literal
|
|
13
13
|
* straight to `new`.
|
|
14
|
-
*
|
|
15
|
-
* `typeParams` and `typeRef` remain mutually exclusive (one or the
|
|
16
|
-
* other, not both); the constructor preserves whichever caller-side
|
|
17
|
-
* choice the input encodes.
|
|
18
14
|
*/
|
|
19
15
|
type StorageColumnMultiplicity = false | {
|
|
20
16
|
readonly elementNullable: boolean;
|
|
@@ -25,7 +21,6 @@ type StorageColumnInput = {
|
|
|
25
21
|
readonly codecId: string;
|
|
26
22
|
readonly nullable: boolean;
|
|
27
23
|
readonly typeParams?: Record<string, unknown>;
|
|
28
|
-
readonly typeRef?: string;
|
|
29
24
|
readonly default?: ColumnDefault;
|
|
30
25
|
readonly control?: ControlPolicy;
|
|
31
26
|
readonly valueSet?: ValueSetRef;
|
|
@@ -50,7 +45,6 @@ declare class StorageColumn extends SqlNode {
|
|
|
50
45
|
readonly nullable: boolean;
|
|
51
46
|
readonly many: StorageColumnMultiplicity;
|
|
52
47
|
readonly typeParams?: Record<string, unknown>;
|
|
53
|
-
readonly typeRef?: string;
|
|
54
48
|
readonly default?: ColumnDefault;
|
|
55
49
|
readonly control?: ControlPolicy;
|
|
56
50
|
readonly valueSet?: ValueSetRef;
|
|
@@ -101,4 +95,4 @@ declare class StorageTable extends SqlNode {
|
|
|
101
95
|
}
|
|
102
96
|
//#endregion
|
|
103
97
|
export { StorageTableInput as i, StorageColumnInput as n, StorageTable as r, StorageColumn as t };
|
|
104
|
-
//# sourceMappingURL=storage-table-
|
|
98
|
+
//# sourceMappingURL=storage-table-Bf1ZjnxO-NvkG2pgq.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"storage-table-Bf1ZjnxO-NvkG2pgq.d.mts","names":[],"sources":["../../../../2-sql/1-core/contract/dist/storage-table-Bf1ZjnxO.d.mts"],"mappings":";;;;;;;;;;;;;;KAaK;WACM;;KAEN;;WAEM;WACA;WACA;WACA,aAAa;WACb,UAAU;WACV,UAAU;WACV,WAAW;WACX,OAAO;;;;;;;;;;;;;;;cAeJ,sBAAsB;WACzB;WACA;WACA;WACA,MAAM;WACN,aAAa;WACb,UAAU;WACV,UAAU;WACV,WAAW;EACpB,YAAY,OAAO;SACZ,KAAK,OAAO,gBAAgB,qBAAqB;;;;UAIhD;WACC,SAAS,eAAe,gBAAgB;WACxC,aAAa,aAAa;WAC1B,SAAS,cAAc,mBAAmB;WAC1C,SAAS,cAAc,QAAQ;WAC/B,aAAa,cAAc,aAAa;WACxC,UAAU;WACV,SAAS,cAAc,kBAAkB;;;;;;;;;;;;;;cActC,qBAAqB;WACxB,SAAS,SAAS,eAAe;WACjC,SAAS,cAAc;WACvB,SAAS,cAAc;WACvB,aAAa,cAAc;WAC3B,aAAa;WACb,UAAU;WACV,SAAS,cAAc;EAChC,YAAY,OAAO;;;;;;;;SAQZ,GAAG,OAAO,2BAA2B,SAAS;SAC9C,OAAO,OAAO,0BAA0B,6BAA6B,SAAS"}
|
|
@@ -4,7 +4,7 @@ import { ContractValidationError } from "@prisma/orm-framework/contract/contract
|
|
|
4
4
|
import { IRNodeBase, freezeNode } from "@prisma/orm-framework/components/ir";
|
|
5
5
|
import { InternalError } from "@prisma/orm-framework/utils/internal-error";
|
|
6
6
|
import { asNamespaceId } from "@prisma/orm-framework/contract/types";
|
|
7
|
-
//#region ../../../2-sql/1-core/contract/dist/storage-table-
|
|
7
|
+
//#region ../../../2-sql/1-core/contract/dist/storage-table-DDvN83mw.mjs
|
|
8
8
|
/**
|
|
9
9
|
* SQL family IR node base. Carries the family-level `kind` discriminator
|
|
10
10
|
* `'sql'` and inherits the framework's `freezeNode` affordance.
|
|
@@ -235,7 +235,6 @@ var StorageColumn = class StorageColumn extends SqlNode {
|
|
|
235
235
|
this.nullable = input.nullable;
|
|
236
236
|
this.many = input.many ?? false;
|
|
237
237
|
if (input.typeParams !== void 0) this.typeParams = input.typeParams;
|
|
238
|
-
if (input.typeRef !== void 0) this.typeRef = input.typeRef;
|
|
239
238
|
if (input.default !== void 0) this.default = input.default;
|
|
240
239
|
if (input.control !== void 0) this.control = input.control;
|
|
241
240
|
if (input.valueSet !== void 0) this.valueSet = input.valueSet;
|
|
@@ -306,4 +305,4 @@ var StorageTable = class StorageTable extends SqlNode {
|
|
|
306
305
|
//#endregion
|
|
307
306
|
export { PrimaryKey as a, StorageTable as c, Index as i, UniqueConstraint as l, ForeignKey as n, SqlNode as o, ForeignKeyReference as r, StorageColumn as s, CheckConstraint as t };
|
|
308
307
|
|
|
309
|
-
//# sourceMappingURL=storage-table-
|
|
308
|
+
//# sourceMappingURL=storage-table-DDvN83mw-CbCFr5wm.mjs.map
|