@noy-db/hub 0.6.0-pre.22 → 0.6.0-pre.23

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.
Files changed (348) hide show
  1. package/CHANGELOG.md +35 -0
  2. package/dist/api-ETB5Y4DY.js +20 -0
  3. package/dist/attestation/index.js +16 -16
  4. package/dist/{backup-4PZAH67W.js → backup-UOLAXOJ4.js} +10 -10
  5. package/dist/blobs/index.js +20 -18
  6. package/dist/blobs/index.js.map +1 -1
  7. package/dist/broker/index.js +10 -10
  8. package/dist/cargo/index.js +26 -26
  9. package/dist/{chunk-QMJI5VHV.js → chunk-22VRCUV2.js} +2 -2
  10. package/dist/{chunk-GWJJ5CK3.js → chunk-23ODLABM.js} +4 -4
  11. package/dist/{chunk-WRGNEAUZ.js → chunk-2DHEBIJA.js} +2 -2
  12. package/dist/{chunk-DUUARUZI.js → chunk-2LHPMFSR.js} +2 -2
  13. package/dist/{chunk-BPLSGN4X.js → chunk-2QN6NPV6.js} +2 -2
  14. package/dist/{chunk-OCW3IM2F.js → chunk-3UIS6O6N.js} +3 -3
  15. package/dist/{chunk-MBZFAJKM.js → chunk-3ZOER5GD.js} +6 -2
  16. package/dist/chunk-3ZOER5GD.js.map +1 -0
  17. package/dist/{chunk-3TWEXEKX.js → chunk-4UZDDS4S.js} +2 -2
  18. package/dist/{chunk-HRSEAGLI.js → chunk-5FRZ7YYU.js} +2 -2
  19. package/dist/{chunk-F3BICEMK.js → chunk-5MU7PUNA.js} +2 -2
  20. package/dist/{chunk-F5IFR56V.js → chunk-66X4XWTM.js} +6 -6
  21. package/dist/{chunk-KYUKZIW5.js → chunk-6G4NORTR.js} +2 -2
  22. package/dist/{chunk-PGHSH4TY.js → chunk-6W3BZCW6.js} +3 -3
  23. package/dist/{chunk-H6K24KLL.js → chunk-6ZN6X2LW.js} +4 -4
  24. package/dist/{chunk-WUNRUSBJ.js → chunk-6ZTPSVY7.js} +2 -2
  25. package/dist/{chunk-WKT7NNNR.js → chunk-7DRKK5FQ.js} +3 -3
  26. package/dist/{chunk-BXHG26KN.js → chunk-7LWBD3NO.js} +2 -2
  27. package/dist/{chunk-RT7CWTUG.js → chunk-7W765AVV.js} +6 -6
  28. package/dist/{chunk-AGETRKC5.js → chunk-7ZPAL3F7.js} +2 -2
  29. package/dist/{chunk-FFESJQ5A.js → chunk-AK6EWGDO.js} +5 -5
  30. package/dist/{chunk-REKDM67V.js → chunk-ATSIGJRX.js} +2 -2
  31. package/dist/{chunk-NHXIFF4Y.js → chunk-AZPPARMG.js} +6 -6
  32. package/dist/{chunk-VKYEEJJ2.js → chunk-B3X6S37C.js} +2 -2
  33. package/dist/{chunk-4IPP2P74.js → chunk-BNGGSNO7.js} +2 -2
  34. package/dist/{chunk-PNXJV4OS.js → chunk-BYX3AUXH.js} +9 -7
  35. package/dist/chunk-BYX3AUXH.js.map +1 -0
  36. package/dist/{chunk-YOMI3ZCA.js → chunk-C7B3XUI4.js} +2 -2
  37. package/dist/{chunk-TKLQWOTY.js → chunk-CJU3KXHJ.js} +2 -2
  38. package/dist/{chunk-FKZI4NSG.js → chunk-CWYTN4IK.js} +5 -5
  39. package/dist/{chunk-NB2CKJ27.js → chunk-D5DZ4R7X.js} +2 -2
  40. package/dist/{chunk-YF3CIA6E.js → chunk-DEKA2MV3.js} +2 -2
  41. package/dist/{chunk-VMYXYFPX.js → chunk-DG4KFJNA.js} +2 -2
  42. package/dist/{chunk-JSTQGUE5.js → chunk-DRVF2YS5.js} +15 -10
  43. package/dist/chunk-DRVF2YS5.js.map +1 -0
  44. package/dist/{chunk-PWK3SSNB.js → chunk-DXJXVWWE.js} +4 -4
  45. package/dist/{chunk-ESXVNASI.js → chunk-DZBZCFS7.js} +5 -5
  46. package/dist/{chunk-VWPJX5B3.js → chunk-FNCX4N7X.js} +4 -4
  47. package/dist/{chunk-DIVPOJPV.js → chunk-FUE2KPKM.js} +6 -6
  48. package/dist/{chunk-DIYI32MG.js → chunk-G4577GK7.js} +4 -4
  49. package/dist/{chunk-D5EXZVQC.js → chunk-G6DAESDS.js} +5 -5
  50. package/dist/{chunk-REQJLII3.js → chunk-GAZTPQ3D.js} +2 -2
  51. package/dist/{chunk-KMGAFLCK.js → chunk-GJ5TMHKC.js} +4 -4
  52. package/dist/{chunk-4BYZIQ5T.js → chunk-GNSLP7KA.js} +2 -2
  53. package/dist/{chunk-PKUJ3JLQ.js → chunk-HKANJAOP.js} +14 -1
  54. package/dist/{chunk-PKUJ3JLQ.js.map → chunk-HKANJAOP.js.map} +1 -1
  55. package/dist/{chunk-RJYPFCID.js → chunk-I3D67XD7.js} +4 -4
  56. package/dist/{chunk-L3AM6EGU.js → chunk-ISRAQIYY.js} +5 -5
  57. package/dist/{chunk-H3SEW5HB.js → chunk-J2KGT2A5.js} +6 -6
  58. package/dist/{chunk-OIW75CLW.js → chunk-JMN3I4OC.js} +4 -4
  59. package/dist/{chunk-4O52JH3C.js → chunk-JO4MRPEY.js} +5 -5
  60. package/dist/{chunk-ZUDIY7YP.js → chunk-JXFQEOAQ.js} +5 -5
  61. package/dist/{chunk-23XKHFNT.js → chunk-KF34JCIJ.js} +3 -3
  62. package/dist/{chunk-2DFE4TUE.js → chunk-KKVVBFKW.js} +3 -3
  63. package/dist/{chunk-MQFKH3ZJ.js → chunk-L374ZR75.js} +3 -3
  64. package/dist/{chunk-WFC2GHJG.js → chunk-L5PTLL7A.js} +3 -3
  65. package/dist/{chunk-FGZ7GJXO.js → chunk-LBDG6FHB.js} +3 -3
  66. package/dist/{chunk-XZZIZ544.js → chunk-LIWA5ROZ.js} +51 -16
  67. package/dist/chunk-LIWA5ROZ.js.map +1 -0
  68. package/dist/{chunk-A66LJYFG.js → chunk-LPVZDTQF.js} +131 -17
  69. package/dist/chunk-LPVZDTQF.js.map +1 -0
  70. package/dist/{chunk-LLLSK7UQ.js → chunk-LYQUFIHL.js} +2 -2
  71. package/dist/{chunk-7JOXCSDU.js → chunk-LZHIYH32.js} +2 -2
  72. package/dist/{chunk-VYLC5KAT.js → chunk-M2KVSM43.js} +2 -2
  73. package/dist/{chunk-ANYVM4SX.js → chunk-O2A5YCFF.js} +2 -2
  74. package/dist/{chunk-H27DIXOV.js → chunk-OGB2UTBC.js} +5 -5
  75. package/dist/{chunk-IUQPNAGR.js → chunk-OMXUQAZJ.js} +3 -3
  76. package/dist/{chunk-7LJA7T4W.js → chunk-PFHF3A72.js} +3 -3
  77. package/dist/{chunk-AELW6OJZ.js → chunk-PUGHLCBW.js} +2 -2
  78. package/dist/{chunk-BFNBYT62.js → chunk-R6BGN6IY.js} +2 -2
  79. package/dist/{chunk-6ZGDIN2D.js → chunk-RBBTJ2HY.js} +3 -3
  80. package/dist/{chunk-FHEVZQQY.js → chunk-RGUAY5IX.js} +4 -4
  81. package/dist/{chunk-O5QXH7U7.js → chunk-RQQIB7CD.js} +2 -2
  82. package/dist/{chunk-M3FKPVOU.js → chunk-RTKREHPV.js} +2 -2
  83. package/dist/{chunk-M7VSXBUL.js → chunk-SIACMXFK.js} +8 -8
  84. package/dist/{chunk-JPVJTTHU.js → chunk-SZFNO7L4.js} +3 -3
  85. package/dist/{chunk-OBPL43F3.js → chunk-TA67ZQUH.js} +53 -6
  86. package/dist/chunk-TA67ZQUH.js.map +1 -0
  87. package/dist/{chunk-FUIG7QSS.js → chunk-TWELPVXG.js} +3 -3
  88. package/dist/{chunk-CW3VJARJ.js → chunk-U5ZDYJLQ.js} +3 -3
  89. package/dist/{chunk-SRR22EW2.js → chunk-UW5YKCE4.js} +6 -6
  90. package/dist/{chunk-QTWWZ25B.js → chunk-UWRVDBDC.js} +10 -10
  91. package/dist/{chunk-QK2QAMF7.js → chunk-VNPSPQNN.js} +10 -10
  92. package/dist/{chunk-NCAMIRFB.js → chunk-VXH5Z22C.js} +2 -2
  93. package/dist/{chunk-ZAZW5LLF.js → chunk-WBFJZCDJ.js} +2 -2
  94. package/dist/{chunk-A5YEUQOY.js → chunk-WBRLSPA7.js} +2 -2
  95. package/dist/{chunk-HZIIDYJV.js → chunk-WG66ZPEV.js} +4 -4
  96. package/dist/{chunk-2VMCJUK6.js → chunk-XXONVJWA.js} +5 -5
  97. package/dist/{chunk-47F6AI2K.js → chunk-YLIGPHN4.js} +3 -3
  98. package/dist/{chunk-XPTYXXMD.js → chunk-YNWBBHQK.js} +2 -2
  99. package/dist/{chunk-L2YYIQYR.js → chunk-Z6UMKUAI.js} +2 -2
  100. package/dist/{chunk-OZ5QBLEL.js → chunk-Z7AHYSZF.js} +5 -5
  101. package/dist/{chunk-6QMOJTC6.js → chunk-ZA3RBGT3.js} +2 -2
  102. package/dist/{chunk-HUEG3YP4.js → chunk-ZILONQGE.js} +93 -78
  103. package/dist/chunk-ZILONQGE.js.map +1 -0
  104. package/dist/{chunk-UQUWSM33.js → chunk-ZKZXS352.js} +5 -5
  105. package/dist/{chunk-IPA6ODWG.js → chunk-ZLU3IWHK.js} +3 -3
  106. package/dist/{chunk-4RZTW5JH.js → chunk-ZYG4UWHF.js} +2 -2
  107. package/dist/classified/index.js +4 -4
  108. package/dist/{classified-marker-EPL2NX3H.js → classified-marker-RYWYYZDB.js} +3 -3
  109. package/dist/{collection-facade-3DN4ETEP.js → collection-facade-XV3IMJBO.js} +15 -15
  110. package/dist/{computed-UXN4AMI5.js → computed-M4QZVSPX.js} +3 -3
  111. package/dist/consent/index.js +7 -7
  112. package/dist/cover/index.js +7 -7
  113. package/dist/custody/index.js +9 -9
  114. package/dist/{dead-filter-56AYTNAO.js → dead-filter-DRKJDNSF.js} +2 -2
  115. package/dist/debug/index.js +1 -1
  116. package/dist/{delegation-MCCWCFZA.js → delegation-UEJN2LDC.js} +9 -9
  117. package/dist/derivations/index.js +10 -10
  118. package/dist/{derive-BSAF6N5X.js → derive-WIWSPZ5M.js} +8 -8
  119. package/dist/directory/index.js +8 -8
  120. package/dist/{dispatch-UPZW4MAO.js → dispatch-2ZE7Z5V2.js} +16 -16
  121. package/dist/{dispatch-JM7X5BLP.js → dispatch-KNWYDUYM.js} +9 -6
  122. package/dist/dispatch-KNWYDUYM.js.map +1 -0
  123. package/dist/{enclave-CCXI3WEU.js → enclave-VNHDWCB6.js} +7 -7
  124. package/dist/executor-4SMYWPSU.js +29 -0
  125. package/dist/executor-BJ7PCXCV.js +9 -0
  126. package/dist/executor-O4UP4M3C.js +9 -0
  127. package/dist/export-accessible-A3N2V4IX.js +23 -0
  128. package/dist/extract-partition-3EUJXWYG.js +38 -0
  129. package/dist/{fanout-sidecar-2EHAV6UP.js → fanout-sidecar-PBEVZ5IQ.js} +7 -7
  130. package/dist/find-W2DL2BEE.js +11 -0
  131. package/dist/forget/index.js +7 -7
  132. package/dist/guards/index.js +4 -4
  133. package/dist/history/index.js +11 -11
  134. package/dist/i18n/index.js +12 -12
  135. package/dist/index.d.ts +1 -1
  136. package/dist/index.js +88 -86
  137. package/dist/index.js.map +1 -1
  138. package/dist/indexing/index.js +2 -2
  139. package/dist/introspection/index.js +9 -9
  140. package/dist/issue-NLJ3FCKL.js +19 -0
  141. package/dist/kernel/collection.d.ts +8 -2
  142. package/dist/kernel/errors.d.ts +26 -0
  143. package/dist/kernel/refs.d.ts +3 -1
  144. package/dist/kernel/via/reconcile.d.ts +12 -0
  145. package/dist/{ledger-TZIDVW22.js → ledger-DDIDLWA3.js} +9 -9
  146. package/dist/liberate-EPTCY3DF.js +24 -0
  147. package/dist/{link-set-VOMRQB2H.js → link-set-2AYA6BEI.js} +9 -9
  148. package/dist/{managed-secret-N6FWB5LX.js → managed-secret-6QTGWZTW.js} +7 -7
  149. package/dist/materialized-views/index.js +18 -18
  150. package/dist/{migrate-cek-UEO2EUWI.js → migrate-cek-YBNJDJ2Q.js} +2 -2
  151. package/dist/money/index.js +4 -4
  152. package/dist/noydb-RFBNRUHH.js +85 -0
  153. package/dist/overlay-views/index.js +4 -4
  154. package/dist/periods/index.js +10 -10
  155. package/dist/pod/index.js +51 -50
  156. package/dist/{pod-handle-D6ZRTO4N.js → pod-handle-77YAUM4J.js} +7 -7
  157. package/dist/policy/index.js +7 -7
  158. package/dist/portability/index.js +8 -8
  159. package/dist/{post-register-XVGHYYSB.js → post-register-WBDTOLWD.js} +6 -6
  160. package/dist/query/index.js +3 -3
  161. package/dist/reduce/index.js +4 -4
  162. package/dist/{register-FVUE46K4.js → register-VSPL7VRW.js} +13 -13
  163. package/dist/registry-A7JADQXC.js +9 -0
  164. package/dist/registry-AOPJN2V4.js +18 -0
  165. package/dist/registry-I4I3QIQ6.js +9 -0
  166. package/dist/registry-QSMKWF4O.js +19 -0
  167. package/dist/{request-withdrawal-WS7PXD7B.js → request-withdrawal-VL5N623Q.js} +12 -12
  168. package/dist/{reveal-Z62PLVJT.js → reveal-Z2X4JW6E.js} +4 -4
  169. package/dist/{revoke-JH4VQTJ3.js → revoke-XQ5STGT4.js} +9 -9
  170. package/dist/satellites/index.js +1 -1
  171. package/dist/schema-update/index.js +2 -2
  172. package/dist/sealed-record/index.js +10 -10
  173. package/dist/search/index.js +4 -4
  174. package/dist/{seed-R2JK2YQK.js → seed-WJWCFPZL.js} +9 -9
  175. package/dist/sequence/index.js +7 -7
  176. package/dist/session/index.js +7 -7
  177. package/dist/shadow/index.js +2 -2
  178. package/dist/{signer-AFV6AXSN.js → signer-N5TGVOTN.js} +8 -8
  179. package/dist/snapshots/index.js +8 -8
  180. package/dist/{stale-FVK3WRMM.js → stale-MIO5KGEP.js} +8 -8
  181. package/dist/{storage-EIM5HO2O.js → storage-NLYOMCDM.js} +8 -8
  182. package/dist/{store-coordination-provider-HIPOZMC2.js → store-coordination-provider-XCX77ZBE.js} +7 -7
  183. package/dist/sync/index.js +8 -8
  184. package/dist/team/index.js +12 -12
  185. package/dist/tiers/index.js +9 -9
  186. package/dist/to/index.js +1 -1
  187. package/dist/transactions/index.js +3 -3
  188. package/dist/util/index.js +1 -1
  189. package/dist/vault-head/index.js +6 -6
  190. package/dist/{verify-KYICK5IW.js → verify-5QI3DGO2.js} +5 -5
  191. package/dist/via/blob/index.d.ts +3 -0
  192. package/dist/walk-G5OAA3RE.js +21 -0
  193. package/dist/with-formula/materialized-views/dependency-analyzer.d.ts +4 -0
  194. package/dist/with-formula/materialized-views/projection-legs.d.ts +59 -0
  195. package/dist/with-formula/materialized-views/registry.d.ts +50 -0
  196. package/dist/with-formula/materialized-views/types.d.ts +68 -10
  197. package/dist/with-shape/blobs/blob-compaction.d.ts +13 -0
  198. package/dist/with-shape/blobs/blob-set.d.ts +3 -1
  199. package/dist/with-shape/blobs/orphan-report.d.ts +62 -0
  200. package/dist/{withdraw-accessible-JYX3SPVY.js → withdraw-accessible-H7G2AMSP.js} +11 -11
  201. package/package.json +3 -3
  202. package/dist/api-D6DBNTOS.js +0 -20
  203. package/dist/chunk-A66LJYFG.js.map +0 -1
  204. package/dist/chunk-HUEG3YP4.js.map +0 -1
  205. package/dist/chunk-JSTQGUE5.js.map +0 -1
  206. package/dist/chunk-MBZFAJKM.js.map +0 -1
  207. package/dist/chunk-OBPL43F3.js.map +0 -1
  208. package/dist/chunk-PNXJV4OS.js.map +0 -1
  209. package/dist/chunk-XZZIZ544.js.map +0 -1
  210. package/dist/dispatch-JM7X5BLP.js.map +0 -1
  211. package/dist/executor-6YQYFGHK.js +0 -9
  212. package/dist/executor-GLKPMISJ.js +0 -9
  213. package/dist/executor-ZEIX7Y7I.js +0 -29
  214. package/dist/export-accessible-SDIQEFHQ.js +0 -23
  215. package/dist/extract-partition-K232SO2V.js +0 -38
  216. package/dist/find-GKFC5753.js +0 -11
  217. package/dist/issue-QTQYQJCB.js +0 -19
  218. package/dist/liberate-FOK7RFYQ.js +0 -24
  219. package/dist/noydb-3BBLBSHI.js +0 -84
  220. package/dist/registry-7PBVHSD5.js +0 -19
  221. package/dist/registry-CCXD57GV.js +0 -18
  222. package/dist/registry-K75FRKSU.js +0 -9
  223. package/dist/registry-KZYPKIOF.js +0 -9
  224. package/dist/walk-FV6JFWXV.js +0 -21
  225. /package/dist/{api-D6DBNTOS.js.map → api-ETB5Y4DY.js.map} +0 -0
  226. /package/dist/{backup-4PZAH67W.js.map → backup-UOLAXOJ4.js.map} +0 -0
  227. /package/dist/{chunk-QMJI5VHV.js.map → chunk-22VRCUV2.js.map} +0 -0
  228. /package/dist/{chunk-GWJJ5CK3.js.map → chunk-23ODLABM.js.map} +0 -0
  229. /package/dist/{chunk-WRGNEAUZ.js.map → chunk-2DHEBIJA.js.map} +0 -0
  230. /package/dist/{chunk-DUUARUZI.js.map → chunk-2LHPMFSR.js.map} +0 -0
  231. /package/dist/{chunk-BPLSGN4X.js.map → chunk-2QN6NPV6.js.map} +0 -0
  232. /package/dist/{chunk-OCW3IM2F.js.map → chunk-3UIS6O6N.js.map} +0 -0
  233. /package/dist/{chunk-3TWEXEKX.js.map → chunk-4UZDDS4S.js.map} +0 -0
  234. /package/dist/{chunk-HRSEAGLI.js.map → chunk-5FRZ7YYU.js.map} +0 -0
  235. /package/dist/{chunk-F3BICEMK.js.map → chunk-5MU7PUNA.js.map} +0 -0
  236. /package/dist/{chunk-F5IFR56V.js.map → chunk-66X4XWTM.js.map} +0 -0
  237. /package/dist/{chunk-KYUKZIW5.js.map → chunk-6G4NORTR.js.map} +0 -0
  238. /package/dist/{chunk-PGHSH4TY.js.map → chunk-6W3BZCW6.js.map} +0 -0
  239. /package/dist/{chunk-H6K24KLL.js.map → chunk-6ZN6X2LW.js.map} +0 -0
  240. /package/dist/{chunk-WUNRUSBJ.js.map → chunk-6ZTPSVY7.js.map} +0 -0
  241. /package/dist/{chunk-WKT7NNNR.js.map → chunk-7DRKK5FQ.js.map} +0 -0
  242. /package/dist/{chunk-BXHG26KN.js.map → chunk-7LWBD3NO.js.map} +0 -0
  243. /package/dist/{chunk-RT7CWTUG.js.map → chunk-7W765AVV.js.map} +0 -0
  244. /package/dist/{chunk-AGETRKC5.js.map → chunk-7ZPAL3F7.js.map} +0 -0
  245. /package/dist/{chunk-FFESJQ5A.js.map → chunk-AK6EWGDO.js.map} +0 -0
  246. /package/dist/{chunk-REKDM67V.js.map → chunk-ATSIGJRX.js.map} +0 -0
  247. /package/dist/{chunk-NHXIFF4Y.js.map → chunk-AZPPARMG.js.map} +0 -0
  248. /package/dist/{chunk-VKYEEJJ2.js.map → chunk-B3X6S37C.js.map} +0 -0
  249. /package/dist/{chunk-4IPP2P74.js.map → chunk-BNGGSNO7.js.map} +0 -0
  250. /package/dist/{chunk-YOMI3ZCA.js.map → chunk-C7B3XUI4.js.map} +0 -0
  251. /package/dist/{chunk-TKLQWOTY.js.map → chunk-CJU3KXHJ.js.map} +0 -0
  252. /package/dist/{chunk-FKZI4NSG.js.map → chunk-CWYTN4IK.js.map} +0 -0
  253. /package/dist/{chunk-NB2CKJ27.js.map → chunk-D5DZ4R7X.js.map} +0 -0
  254. /package/dist/{chunk-YF3CIA6E.js.map → chunk-DEKA2MV3.js.map} +0 -0
  255. /package/dist/{chunk-VMYXYFPX.js.map → chunk-DG4KFJNA.js.map} +0 -0
  256. /package/dist/{chunk-PWK3SSNB.js.map → chunk-DXJXVWWE.js.map} +0 -0
  257. /package/dist/{chunk-ESXVNASI.js.map → chunk-DZBZCFS7.js.map} +0 -0
  258. /package/dist/{chunk-VWPJX5B3.js.map → chunk-FNCX4N7X.js.map} +0 -0
  259. /package/dist/{chunk-DIVPOJPV.js.map → chunk-FUE2KPKM.js.map} +0 -0
  260. /package/dist/{chunk-DIYI32MG.js.map → chunk-G4577GK7.js.map} +0 -0
  261. /package/dist/{chunk-D5EXZVQC.js.map → chunk-G6DAESDS.js.map} +0 -0
  262. /package/dist/{chunk-REQJLII3.js.map → chunk-GAZTPQ3D.js.map} +0 -0
  263. /package/dist/{chunk-KMGAFLCK.js.map → chunk-GJ5TMHKC.js.map} +0 -0
  264. /package/dist/{chunk-4BYZIQ5T.js.map → chunk-GNSLP7KA.js.map} +0 -0
  265. /package/dist/{chunk-RJYPFCID.js.map → chunk-I3D67XD7.js.map} +0 -0
  266. /package/dist/{chunk-L3AM6EGU.js.map → chunk-ISRAQIYY.js.map} +0 -0
  267. /package/dist/{chunk-H3SEW5HB.js.map → chunk-J2KGT2A5.js.map} +0 -0
  268. /package/dist/{chunk-OIW75CLW.js.map → chunk-JMN3I4OC.js.map} +0 -0
  269. /package/dist/{chunk-4O52JH3C.js.map → chunk-JO4MRPEY.js.map} +0 -0
  270. /package/dist/{chunk-ZUDIY7YP.js.map → chunk-JXFQEOAQ.js.map} +0 -0
  271. /package/dist/{chunk-23XKHFNT.js.map → chunk-KF34JCIJ.js.map} +0 -0
  272. /package/dist/{chunk-2DFE4TUE.js.map → chunk-KKVVBFKW.js.map} +0 -0
  273. /package/dist/{chunk-MQFKH3ZJ.js.map → chunk-L374ZR75.js.map} +0 -0
  274. /package/dist/{chunk-WFC2GHJG.js.map → chunk-L5PTLL7A.js.map} +0 -0
  275. /package/dist/{chunk-FGZ7GJXO.js.map → chunk-LBDG6FHB.js.map} +0 -0
  276. /package/dist/{chunk-LLLSK7UQ.js.map → chunk-LYQUFIHL.js.map} +0 -0
  277. /package/dist/{chunk-7JOXCSDU.js.map → chunk-LZHIYH32.js.map} +0 -0
  278. /package/dist/{chunk-VYLC5KAT.js.map → chunk-M2KVSM43.js.map} +0 -0
  279. /package/dist/{chunk-ANYVM4SX.js.map → chunk-O2A5YCFF.js.map} +0 -0
  280. /package/dist/{chunk-H27DIXOV.js.map → chunk-OGB2UTBC.js.map} +0 -0
  281. /package/dist/{chunk-IUQPNAGR.js.map → chunk-OMXUQAZJ.js.map} +0 -0
  282. /package/dist/{chunk-7LJA7T4W.js.map → chunk-PFHF3A72.js.map} +0 -0
  283. /package/dist/{chunk-AELW6OJZ.js.map → chunk-PUGHLCBW.js.map} +0 -0
  284. /package/dist/{chunk-BFNBYT62.js.map → chunk-R6BGN6IY.js.map} +0 -0
  285. /package/dist/{chunk-6ZGDIN2D.js.map → chunk-RBBTJ2HY.js.map} +0 -0
  286. /package/dist/{chunk-FHEVZQQY.js.map → chunk-RGUAY5IX.js.map} +0 -0
  287. /package/dist/{chunk-O5QXH7U7.js.map → chunk-RQQIB7CD.js.map} +0 -0
  288. /package/dist/{chunk-M3FKPVOU.js.map → chunk-RTKREHPV.js.map} +0 -0
  289. /package/dist/{chunk-M7VSXBUL.js.map → chunk-SIACMXFK.js.map} +0 -0
  290. /package/dist/{chunk-JPVJTTHU.js.map → chunk-SZFNO7L4.js.map} +0 -0
  291. /package/dist/{chunk-FUIG7QSS.js.map → chunk-TWELPVXG.js.map} +0 -0
  292. /package/dist/{chunk-CW3VJARJ.js.map → chunk-U5ZDYJLQ.js.map} +0 -0
  293. /package/dist/{chunk-SRR22EW2.js.map → chunk-UW5YKCE4.js.map} +0 -0
  294. /package/dist/{chunk-QTWWZ25B.js.map → chunk-UWRVDBDC.js.map} +0 -0
  295. /package/dist/{chunk-QK2QAMF7.js.map → chunk-VNPSPQNN.js.map} +0 -0
  296. /package/dist/{chunk-NCAMIRFB.js.map → chunk-VXH5Z22C.js.map} +0 -0
  297. /package/dist/{chunk-ZAZW5LLF.js.map → chunk-WBFJZCDJ.js.map} +0 -0
  298. /package/dist/{chunk-A5YEUQOY.js.map → chunk-WBRLSPA7.js.map} +0 -0
  299. /package/dist/{chunk-HZIIDYJV.js.map → chunk-WG66ZPEV.js.map} +0 -0
  300. /package/dist/{chunk-2VMCJUK6.js.map → chunk-XXONVJWA.js.map} +0 -0
  301. /package/dist/{chunk-47F6AI2K.js.map → chunk-YLIGPHN4.js.map} +0 -0
  302. /package/dist/{chunk-XPTYXXMD.js.map → chunk-YNWBBHQK.js.map} +0 -0
  303. /package/dist/{chunk-L2YYIQYR.js.map → chunk-Z6UMKUAI.js.map} +0 -0
  304. /package/dist/{chunk-OZ5QBLEL.js.map → chunk-Z7AHYSZF.js.map} +0 -0
  305. /package/dist/{chunk-6QMOJTC6.js.map → chunk-ZA3RBGT3.js.map} +0 -0
  306. /package/dist/{chunk-UQUWSM33.js.map → chunk-ZKZXS352.js.map} +0 -0
  307. /package/dist/{chunk-IPA6ODWG.js.map → chunk-ZLU3IWHK.js.map} +0 -0
  308. /package/dist/{chunk-4RZTW5JH.js.map → chunk-ZYG4UWHF.js.map} +0 -0
  309. /package/dist/{classified-marker-EPL2NX3H.js.map → classified-marker-RYWYYZDB.js.map} +0 -0
  310. /package/dist/{collection-facade-3DN4ETEP.js.map → collection-facade-XV3IMJBO.js.map} +0 -0
  311. /package/dist/{computed-UXN4AMI5.js.map → computed-M4QZVSPX.js.map} +0 -0
  312. /package/dist/{dead-filter-56AYTNAO.js.map → dead-filter-DRKJDNSF.js.map} +0 -0
  313. /package/dist/{delegation-MCCWCFZA.js.map → delegation-UEJN2LDC.js.map} +0 -0
  314. /package/dist/{derive-BSAF6N5X.js.map → derive-WIWSPZ5M.js.map} +0 -0
  315. /package/dist/{dispatch-UPZW4MAO.js.map → dispatch-2ZE7Z5V2.js.map} +0 -0
  316. /package/dist/{enclave-CCXI3WEU.js.map → enclave-VNHDWCB6.js.map} +0 -0
  317. /package/dist/{executor-6YQYFGHK.js.map → executor-4SMYWPSU.js.map} +0 -0
  318. /package/dist/{executor-GLKPMISJ.js.map → executor-BJ7PCXCV.js.map} +0 -0
  319. /package/dist/{executor-ZEIX7Y7I.js.map → executor-O4UP4M3C.js.map} +0 -0
  320. /package/dist/{export-accessible-SDIQEFHQ.js.map → export-accessible-A3N2V4IX.js.map} +0 -0
  321. /package/dist/{extract-partition-K232SO2V.js.map → extract-partition-3EUJXWYG.js.map} +0 -0
  322. /package/dist/{fanout-sidecar-2EHAV6UP.js.map → fanout-sidecar-PBEVZ5IQ.js.map} +0 -0
  323. /package/dist/{find-GKFC5753.js.map → find-W2DL2BEE.js.map} +0 -0
  324. /package/dist/{issue-QTQYQJCB.js.map → issue-NLJ3FCKL.js.map} +0 -0
  325. /package/dist/{ledger-TZIDVW22.js.map → ledger-DDIDLWA3.js.map} +0 -0
  326. /package/dist/{liberate-FOK7RFYQ.js.map → liberate-EPTCY3DF.js.map} +0 -0
  327. /package/dist/{link-set-VOMRQB2H.js.map → link-set-2AYA6BEI.js.map} +0 -0
  328. /package/dist/{managed-secret-N6FWB5LX.js.map → managed-secret-6QTGWZTW.js.map} +0 -0
  329. /package/dist/{migrate-cek-UEO2EUWI.js.map → migrate-cek-YBNJDJ2Q.js.map} +0 -0
  330. /package/dist/{noydb-3BBLBSHI.js.map → noydb-RFBNRUHH.js.map} +0 -0
  331. /package/dist/{pod-handle-D6ZRTO4N.js.map → pod-handle-77YAUM4J.js.map} +0 -0
  332. /package/dist/{post-register-XVGHYYSB.js.map → post-register-WBDTOLWD.js.map} +0 -0
  333. /package/dist/{register-FVUE46K4.js.map → register-VSPL7VRW.js.map} +0 -0
  334. /package/dist/{registry-7PBVHSD5.js.map → registry-A7JADQXC.js.map} +0 -0
  335. /package/dist/{registry-CCXD57GV.js.map → registry-AOPJN2V4.js.map} +0 -0
  336. /package/dist/{registry-K75FRKSU.js.map → registry-I4I3QIQ6.js.map} +0 -0
  337. /package/dist/{registry-KZYPKIOF.js.map → registry-QSMKWF4O.js.map} +0 -0
  338. /package/dist/{request-withdrawal-WS7PXD7B.js.map → request-withdrawal-VL5N623Q.js.map} +0 -0
  339. /package/dist/{reveal-Z62PLVJT.js.map → reveal-Z2X4JW6E.js.map} +0 -0
  340. /package/dist/{revoke-JH4VQTJ3.js.map → revoke-XQ5STGT4.js.map} +0 -0
  341. /package/dist/{seed-R2JK2YQK.js.map → seed-WJWCFPZL.js.map} +0 -0
  342. /package/dist/{signer-AFV6AXSN.js.map → signer-N5TGVOTN.js.map} +0 -0
  343. /package/dist/{stale-FVK3WRMM.js.map → stale-MIO5KGEP.js.map} +0 -0
  344. /package/dist/{storage-EIM5HO2O.js.map → storage-NLYOMCDM.js.map} +0 -0
  345. /package/dist/{store-coordination-provider-HIPOZMC2.js.map → store-coordination-provider-XCX77ZBE.js.map} +0 -0
  346. /package/dist/{verify-KYICK5IW.js.map → verify-5QI3DGO2.js.map} +0 -0
  347. /package/dist/{walk-FV6JFWXV.js.map → walk-G5OAA3RE.js.map} +0 -0
  348. /package/dist/{withdraw-accessible-JYX3SPVY.js.map → withdraw-accessible-H7G2AMSP.js.map} +0 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,40 @@
1
1
  # Changelog — hub
2
2
 
3
+ ## 0.6.0-pre.23
4
+
5
+ ### Minor Changes
6
+
7
+ - Query-form materialized views can join a declared ref, and a late `refs` declaration is no longer silently discarded.
8
+
9
+ **#1141 — `refs` declared on an already-constructed collection were dropped.** The declaration fan-out ran only when `vault.collection()` missed its cache, so any earlier touch of the collection silently discarded a later `refs` declaration: strict FK enforcement never engaged (a dangling `put()` was accepted) and `.join()` kept reporting "no ref() declared". `refs` now late-attaches through the same reconcile ladder every other declaration already used. An identical redeclaration stays a no-op; a conflicting one still throws.
10
+
11
+ **#1139 — a query-form MV that joins a declared FK threw at `openVault()`, with no ordering that avoided it.** MV strategies register during `openVault()`, but a collection's refs can only be declared after it returns, so the plan was built before any ref could exist. Such a strategy is now parked and replanned on the first write dispatch or `vault.refreshView()`, matching the projection form's timing. Every other planning failure still throws out of `openVault()` immediately — only a not-yet-declared ref defers.
12
+
13
+ Adds `RefNotDeclaredError` to the root barrel: `.join()` now throws it instead of a bare `Error`, with an unchanged message, so the deferral condition is matched on a type rather than on text.
14
+
15
+ - Report blob chunks that outlived their index row (#1133).
16
+
17
+ `vault.compact()` now returns `orphanBlobChunks` — a count of `_blob_chunks` rows whose eTag has no `_blob_index` entry, the distinct eTags involved, a small sample to inspect, and a separate count of ids that do not fit the `{eTag}_{index}` grammar at all. `reportOrphanBlobChunks(store, vault)` is exported from `@noy-db/hub/blobs` for callers that want it on its own.
18
+
19
+ This is the residue #1127 stopped producing: before that fix a crash between deleting a blob's index row and its chunks stranded bodies no reader and no key rotation can reach, which for a legacy blob leaves bytes openable under a retired `_blob` DEK.
20
+
21
+ **It reports and never reclaims, deliberately.** Deciding "orphaned" means trusting `store.list`, and the store is untrusted — one withheld index row would make a live blob's chunks look orphaned, so a reclaim pass would convert withholding, which is reversible, into permanent destruction. A lying store can only inflate this count.
22
+
23
+ - Projection MV legs can attach to another leg's alias (#1140).
24
+
25
+ `ProjectionJoinLeg` gains `from`, naming a previously-declared FORWARD leg. A collect leg then matches against that leg's record id instead of the primary row's, and a forward leg reads its FK off that record — which makes a lookup two FKs away expressible for the first time:
26
+
27
+ ```ts
28
+ joins: [
29
+ { field: "entityId", as: "entity" },
30
+ { from: "entity", collect: "clients", on: "entityId", as: "clients" },
31
+ ];
32
+ ```
33
+
34
+ Every leg previously attached to the primary row, so `bill → entity → client` had no shape: the bill has no `clientId`, and `clients.entityId` refs `entities`, not `bills`. The two workarounds were denormalizing a redundant FK onto the source — reintroducing the duplicated relationship a projection MV exists to avoid — or dropping back to app code and forfeiting the dependency tracking.
35
+
36
+ `from` may only name a leg declared earlier, and only a forward one (a collect leg holds an array, not a record). Both are refused at `withMaterializedView()` construction, alongside the rest of the leg-shape checks. The backward-only rule is also why no depth cap is needed: a cycle cannot be spelled. `from` is folded into the plan summary, so two structurally different projections cannot share a `queryHash`.
37
+
3
38
  ## 0.6.0-pre.22
4
39
 
5
40
  ### Minor Changes
@@ -0,0 +1,20 @@
1
+ import {
2
+ UserApi,
3
+ createUserApi
4
+ } from "./chunk-6W3BZCW6.js";
5
+ import "./chunk-GJ5TMHKC.js";
6
+ import "./chunk-FUE2KPKM.js";
7
+ import "./chunk-PENPHA45.js";
8
+ import "./chunk-OMXUQAZJ.js";
9
+ import "./chunk-PUGHLCBW.js";
10
+ import "./chunk-2LHPMFSR.js";
11
+ import "./chunk-LP7BEXCT.js";
12
+ import "./chunk-RQQIB7CD.js";
13
+ import "./chunk-IGNJOJEP.js";
14
+ import "./chunk-HKANJAOP.js";
15
+ import "./chunk-PZ5AY32C.js";
16
+ export {
17
+ UserApi,
18
+ createUserApi
19
+ };
20
+ //# sourceMappingURL=api-ETB5Y4DY.js.map
@@ -1,42 +1,42 @@
1
1
  import {
2
2
  issueAttestationCore
3
- } from "../chunk-OZ5QBLEL.js";
3
+ } from "../chunk-Z7AHYSZF.js";
4
4
  import {
5
5
  getRevokedDocIdsCore,
6
6
  publishRevocationListCore,
7
7
  revokeDocCore,
8
8
  unrevokeDocCore
9
- } from "../chunk-D5EXZVQC.js";
9
+ } from "../chunk-G6DAESDS.js";
10
10
  import {
11
11
  ATTESTATIONS_COLLECTION
12
- } from "../chunk-GWJJ5CK3.js";
12
+ } from "../chunk-23ODLABM.js";
13
13
  import {
14
14
  NO_ATTESTATION
15
- } from "../chunk-NB2CKJ27.js";
15
+ } from "../chunk-D5DZ4R7X.js";
16
16
  import "../chunk-4AOERLTV.js";
17
- import "../chunk-DIVPOJPV.js";
17
+ import "../chunk-FUE2KPKM.js";
18
18
  import "../chunk-PENPHA45.js";
19
- import "../chunk-IUQPNAGR.js";
20
- import "../chunk-AELW6OJZ.js";
21
- import "../chunk-DUUARUZI.js";
19
+ import "../chunk-OMXUQAZJ.js";
20
+ import "../chunk-PUGHLCBW.js";
21
+ import "../chunk-2LHPMFSR.js";
22
22
  import "../chunk-LP7BEXCT.js";
23
- import "../chunk-O5QXH7U7.js";
23
+ import "../chunk-RQQIB7CD.js";
24
24
  import "../chunk-IGNJOJEP.js";
25
25
  import {
26
26
  AttestationError,
27
27
  AttestationNotEnabledError
28
- } from "../chunk-PKUJ3JLQ.js";
28
+ } from "../chunk-HKANJAOP.js";
29
29
  import "../chunk-PZ5AY32C.js";
30
30
 
31
31
  // src/with-audit/attestation/active.ts
32
32
  function withAttestation() {
33
33
  return {
34
34
  async issueAttestation(ctx, args) {
35
- const { issueAttestationCore: issueAttestationCore2 } = await import("../issue-QTQYQJCB.js");
35
+ const { issueAttestationCore: issueAttestationCore2 } = await import("../issue-NLJ3FCKL.js");
36
36
  return issueAttestationCore2(ctx, args);
37
37
  },
38
38
  async getDocumentSigningPublicKey(deps) {
39
- const { loadSigner, loadOrCreateSigner } = await import("../signer-AFV6AXSN.js");
39
+ const { loadSigner, loadOrCreateSigner } = await import("../signer-N5TGVOTN.js");
40
40
  const existing = await loadSigner(deps.adapter, deps.vault, deps.getDEK);
41
41
  if (existing) return { keyId: existing.keyId, publicKeyB64: existing.publicKeyB64 };
42
42
  if (deps.role !== "owner") {
@@ -46,19 +46,19 @@ function withAttestation() {
46
46
  return { keyId: signer.keyId, publicKeyB64: signer.publicKeyB64 };
47
47
  },
48
48
  async revokeAttestation(ctx, docId) {
49
- const { revokeDocCore: revokeDocCore2 } = await import("../revoke-JH4VQTJ3.js");
49
+ const { revokeDocCore: revokeDocCore2 } = await import("../revoke-XQ5STGT4.js");
50
50
  return revokeDocCore2(ctx, docId);
51
51
  },
52
52
  async unrevokeAttestation(ctx, docId) {
53
- const { unrevokeDocCore: unrevokeDocCore2 } = await import("../revoke-JH4VQTJ3.js");
53
+ const { unrevokeDocCore: unrevokeDocCore2 } = await import("../revoke-XQ5STGT4.js");
54
54
  return unrevokeDocCore2(ctx, docId);
55
55
  },
56
56
  async getRevokedDocIds(ctx) {
57
- const { getRevokedDocIdsCore: getRevokedDocIdsCore2 } = await import("../revoke-JH4VQTJ3.js");
57
+ const { getRevokedDocIdsCore: getRevokedDocIdsCore2 } = await import("../revoke-XQ5STGT4.js");
58
58
  return getRevokedDocIdsCore2(ctx);
59
59
  },
60
60
  async publishRevocationList(ctx) {
61
- const { publishRevocationListCore: publishRevocationListCore2 } = await import("../revoke-JH4VQTJ3.js");
61
+ const { publishRevocationListCore: publishRevocationListCore2 } = await import("../revoke-XQ5STGT4.js");
62
62
  return publishRevocationListCore2(ctx);
63
63
  }
64
64
  };
@@ -3,37 +3,37 @@ import {
3
3
  } from "./chunk-EPFF7LOX.js";
4
4
  import {
5
5
  SCHEMAS_COLLECTION
6
- } from "./chunk-JPVJTTHU.js";
6
+ } from "./chunk-SZFNO7L4.js";
7
7
  import {
8
8
  SEQUENCE_COLLECTION
9
- } from "./chunk-DIYI32MG.js";
9
+ } from "./chunk-G4577GK7.js";
10
10
  import {
11
11
  PERIODS_COLLECTION,
12
12
  PERIOD_ARCHIVES_COLLECTION,
13
13
  PERIOD_FREEZES_COLLECTION,
14
14
  PERIOD_REOPENS_COLLECTION,
15
15
  PERIOD_TARGET_PURGES_COLLECTION
16
- } from "./chunk-NCAMIRFB.js";
16
+ } from "./chunk-VXH5Z22C.js";
17
17
  import {
18
18
  LEDGER_COLLECTION,
19
19
  LEDGER_DELTAS_COLLECTION
20
20
  } from "./chunk-I7FD46FF.js";
21
- import "./chunk-DIVPOJPV.js";
21
+ import "./chunk-FUE2KPKM.js";
22
22
  import {
23
23
  buildRecordEnvelope
24
24
  } from "./chunk-PENPHA45.js";
25
- import "./chunk-IUQPNAGR.js";
26
- import "./chunk-AELW6OJZ.js";
27
- import "./chunk-DUUARUZI.js";
25
+ import "./chunk-OMXUQAZJ.js";
26
+ import "./chunk-PUGHLCBW.js";
27
+ import "./chunk-2LHPMFSR.js";
28
28
  import "./chunk-LP7BEXCT.js";
29
- import "./chunk-O5QXH7U7.js";
29
+ import "./chunk-RQQIB7CD.js";
30
30
  import {
31
31
  NOYDB_BACKUP_VERSION
32
32
  } from "./chunk-IGNJOJEP.js";
33
33
  import {
34
34
  BackupCorruptedError,
35
35
  BackupLedgerError
36
- } from "./chunk-PKUJ3JLQ.js";
36
+ } from "./chunk-HKANJAOP.js";
37
37
  import "./chunk-PZ5AY32C.js";
38
38
 
39
39
  // src/with-pod/backup.ts
@@ -262,4 +262,4 @@ export {
262
262
  loadVault,
263
263
  verifyBackupIntegrity
264
264
  };
265
- //# sourceMappingURL=backup-4PZAH67W.js.map
265
+ //# sourceMappingURL=backup-UOLAXOJ4.js.map
@@ -2,6 +2,15 @@ import {
2
2
  importExternalObjects,
3
3
  memoryObjectProjection
4
4
  } from "../chunk-4Q6HSHHL.js";
5
+ import {
6
+ BLOB_EVICTION_AUDIT_COLLECTION,
7
+ EXPORT_AUDIT_COLLECTION,
8
+ ExportBlobsAbortedError,
9
+ NO_BLOBS,
10
+ createExportBlobsHandle,
11
+ reportOrphanBlobChunks,
12
+ runCompaction
13
+ } from "../chunk-TA67ZQUH.js";
5
14
  import {
6
15
  BLOB_CHUNKS_COLLECTION,
7
16
  BLOB_COLLECTION,
@@ -16,29 +25,21 @@ import {
16
25
  detectMimeType,
17
26
  isPreCompressed,
18
27
  memoryBlobPinStore
19
- } from "../chunk-PNXJV4OS.js";
20
- import {
21
- BLOB_EVICTION_AUDIT_COLLECTION,
22
- EXPORT_AUDIT_COLLECTION,
23
- ExportBlobsAbortedError,
24
- NO_BLOBS,
25
- createExportBlobsHandle,
26
- runCompaction
27
- } from "../chunk-OBPL43F3.js";
28
- import "../chunk-7JOXCSDU.js";
29
- import "../chunk-OCW3IM2F.js";
30
- import "../chunk-WUNRUSBJ.js";
31
- import "../chunk-DIVPOJPV.js";
28
+ } from "../chunk-BYX3AUXH.js";
29
+ import "../chunk-LZHIYH32.js";
30
+ import "../chunk-3UIS6O6N.js";
31
+ import "../chunk-6ZTPSVY7.js";
32
+ import "../chunk-FUE2KPKM.js";
32
33
  import "../chunk-PENPHA45.js";
33
- import "../chunk-IUQPNAGR.js";
34
- import "../chunk-AELW6OJZ.js";
35
- import "../chunk-DUUARUZI.js";
34
+ import "../chunk-OMXUQAZJ.js";
35
+ import "../chunk-PUGHLCBW.js";
36
+ import "../chunk-2LHPMFSR.js";
36
37
  import "../chunk-LP7BEXCT.js";
37
- import "../chunk-O5QXH7U7.js";
38
+ import "../chunk-RQQIB7CD.js";
38
39
  import "../chunk-IGNJOJEP.js";
39
40
  import {
40
41
  BlobOfflineError
41
- } from "../chunk-PKUJ3JLQ.js";
42
+ } from "../chunk-HKANJAOP.js";
42
43
  import "../chunk-PZ5AY32C.js";
43
44
 
44
45
  // src/via/blob/active.ts
@@ -74,6 +75,7 @@ export {
74
75
  isPreCompressed,
75
76
  memoryBlobPinStore,
76
77
  memoryObjectProjection,
78
+ reportOrphanBlobChunks,
77
79
  runCompaction,
78
80
  withBlobs
79
81
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/via/blob/active.ts"],"sourcesContent":["/**\n * Active blob strategy factory. Calling `blobs()` returns a\n * `BlobsStrategy` whose `openSlot` constructs a real `BlobSet` bound\n * to the caller's record. The returned strategy is passed into\n * `createNoydb({ blobsStrategy: blobs() })` to light up the\n * `collection.blob(id)` path.\n *\n * This module is only reachable through the `@noy-db/hub/blobs`\n * subpath — a consumer that never imports the subpath ships none of\n * this (ESM tree-shaking + hub's `\"sideEffects\": false`).\n */\n\nimport { BlobSet } from '../../with-shape/blobs/blob-set.js'\nimport type { BlobsStrategy } from '../../port/with/blob-strategy.js'\nimport { createBlobPinCache } from '../../with-shape/blobs/blob-pinning.js'\nimport type { BlobPinStore } from '../../with-shape/blobs/blob-pinning.js'\n\n/** Options for {@link withBlobs} (#808). */\nexport interface WithBlobsOptions {\n /**\n * Device-local backend for the offline-pin registry + external side-cache\n * (`collection.blob(id).pin()`, the `cacheBudget` LRU stamps). Default:\n * in-memory — pins then last one app session. Supply a durable,\n * DEVICE-LOCAL store (IndexedDB-backed on the web; it must never sync) to\n * keep pins across restarts. See `BlobPinStore`'s doc for the posture.\n */\n readonly pinStore?: BlobPinStore\n}\n\n/**\n * Build a default `BlobsStrategy` ready to pass into `createNoydb`.\n *\n * Named `withBlobs` (plugin-pattern canonical) rather than `blobs` to\n * avoid shadowing the very common local idiom\n * `const blobs = invoices.blob(id)` in user code.\n *\n * One `withBlobs()` instance owns one device-local pin registry + KPI\n * counter set (#808) — treat it as \"this device's\" blob service.\n *\n * @example\n * ```ts\n * import { createNoydb } from '@noy-db/hub'\n * import { withBlobs } from '@noy-db/hub/blobs'\n *\n * const db = await createNoydb({\n * store, user, secret,\n * blobsStrategy: withBlobs(),\n * })\n *\n * // Now live — delegates to BlobSet.\n * const vault = await db.openVault('acme')\n * await vault.collection('invoices').blob('inv-1').put('receipt.pdf', bytes)\n * ```\n */\nexport function withBlobs(options: WithBlobsOptions = {}): BlobsStrategy {\n const pinCache = createBlobPinCache(options.pinStore)\n return {\n openSlot(args) {\n return new BlobSet({ ...args, pinCache })\n },\n cacheStats() {\n return { ...pinCache.stats }\n },\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsDO,SAAS,UAAU,UAA4B,CAAC,GAAkB;AACvE,QAAM,WAAW,mBAAmB,QAAQ,QAAQ;AACpD,SAAO;AAAA,IACL,SAAS,MAAM;AACb,aAAO,IAAI,QAAQ,EAAE,GAAG,MAAM,SAAS,CAAC;AAAA,IAC1C;AAAA,IACA,aAAa;AACX,aAAO,EAAE,GAAG,SAAS,MAAM;AAAA,IAC7B;AAAA,EACF;AACF;","names":[]}
1
+ {"version":3,"sources":["../../src/via/blob/active.ts"],"sourcesContent":["/**\n * Active blob strategy factory. Calling `blobs()` returns a\n * `BlobsStrategy` whose `openSlot` constructs a real `BlobSet` bound\n * to the caller's record. The returned strategy is passed into\n * `createNoydb({ blobsStrategy: blobs() })` to light up the\n * `collection.blob(id)` path.\n *\n * This module is only reachable through the `@noy-db/hub/blobs`\n * subpath — a consumer that never imports the subpath ships none of\n * this (ESM tree-shaking + hub's `\"sideEffects\": false`).\n */\n\nimport { BlobSet } from '../../with-shape/blobs/blob-set.js'\nimport type { BlobsStrategy } from '../../port/with/blob-strategy.js'\nimport { createBlobPinCache } from '../../with-shape/blobs/blob-pinning.js'\nimport type { BlobPinStore } from '../../with-shape/blobs/blob-pinning.js'\n\n/** Options for {@link withBlobs} (#808). */\nexport interface WithBlobsOptions {\n /**\n * Device-local backend for the offline-pin registry + external side-cache\n * (`collection.blob(id).pin()`, the `cacheBudget` LRU stamps). Default:\n * in-memory — pins then last one app session. Supply a durable,\n * DEVICE-LOCAL store (IndexedDB-backed on the web; it must never sync) to\n * keep pins across restarts. See `BlobPinStore`'s doc for the posture.\n */\n readonly pinStore?: BlobPinStore\n}\n\n/**\n * Build a default `BlobsStrategy` ready to pass into `createNoydb`.\n *\n * Named `withBlobs` (plugin-pattern canonical) rather than `blobs` to\n * avoid shadowing the very common local idiom\n * `const blobs = invoices.blob(id)` in user code.\n *\n * One `withBlobs()` instance owns one device-local pin registry + KPI\n * counter set (#808) — treat it as \"this device's\" blob service.\n *\n * @example\n * ```ts\n * import { createNoydb } from '@noy-db/hub'\n * import { withBlobs } from '@noy-db/hub/blobs'\n *\n * const db = await createNoydb({\n * store, user, secret,\n * blobsStrategy: withBlobs(),\n * })\n *\n * // Now live — delegates to BlobSet.\n * const vault = await db.openVault('acme')\n * await vault.collection('invoices').blob('inv-1').put('receipt.pdf', bytes)\n * ```\n */\nexport function withBlobs(options: WithBlobsOptions = {}): BlobsStrategy {\n const pinCache = createBlobPinCache(options.pinStore)\n return {\n openSlot(args) {\n return new BlobSet({ ...args, pinCache })\n },\n cacheStats() {\n return { ...pinCache.stats }\n },\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsDO,SAAS,UAAU,UAA4B,CAAC,GAAkB;AACvE,QAAM,WAAW,mBAAmB,QAAQ,QAAQ;AACpD,SAAO;AAAA,IACL,SAAS,MAAM;AACb,aAAO,IAAI,QAAQ,EAAE,GAAG,MAAM,SAAS,CAAC;AAAA,IAC1C;AAAA,IACA,aAAa;AACX,aAAO,EAAE,GAAG,SAAS,MAAM;AAAA,IAC7B;AAAA,EACF;AACF;","names":[]}
@@ -1,22 +1,22 @@
1
1
  import {
2
2
  NO_BROKER
3
- } from "../chunk-LLLSK7UQ.js";
3
+ } from "../chunk-LYQUFIHL.js";
4
4
  import {
5
5
  issueChallenge,
6
6
  verifyBrokerProof
7
- } from "../chunk-DIVPOJPV.js";
7
+ } from "../chunk-FUE2KPKM.js";
8
8
  import "../chunk-PENPHA45.js";
9
- import "../chunk-IUQPNAGR.js";
10
- import "../chunk-AELW6OJZ.js";
11
- import "../chunk-DUUARUZI.js";
9
+ import "../chunk-OMXUQAZJ.js";
10
+ import "../chunk-PUGHLCBW.js";
11
+ import "../chunk-2LHPMFSR.js";
12
12
  import "../chunk-LP7BEXCT.js";
13
- import "../chunk-O5QXH7U7.js";
13
+ import "../chunk-RQQIB7CD.js";
14
14
  import "../chunk-IGNJOJEP.js";
15
15
  import {
16
16
  BrokerEnrolmentError,
17
17
  BrokerNotEnabledError,
18
18
  BrokerProofError
19
- } from "../chunk-PKUJ3JLQ.js";
19
+ } from "../chunk-HKANJAOP.js";
20
20
  import "../chunk-PZ5AY32C.js";
21
21
 
22
22
  // src/with-party/broker/active.ts
@@ -30,7 +30,7 @@ function withBroker(config) {
30
30
  const cache = /* @__PURE__ */ new Map();
31
31
  return {
32
32
  async enroll(ctx) {
33
- const { enrollSeed } = await import("../seed-R2JK2YQK.js");
33
+ const { enrollSeed } = await import("../seed-WJWCFPZL.js");
34
34
  return enrollSeed({ ...ctx, config });
35
35
  },
36
36
  async rotate(ctx) {
@@ -39,7 +39,7 @@ function withBroker(config) {
39
39
  const inFlight = scoped.map(([, e]) => e.inFlight).filter((p) => p !== void 0);
40
40
  await Promise.allSettled(inFlight);
41
41
  for (const [key] of scoped) cache.delete(key);
42
- const { rotateSeed } = await import("../seed-R2JK2YQK.js");
42
+ const { rotateSeed } = await import("../seed-WJWCFPZL.js");
43
43
  return rotateSeed({ ...ctx, config });
44
44
  },
45
45
  credentialSource(ctx, profile) {
@@ -56,7 +56,7 @@ function withBroker(config) {
56
56
  const skewMs = config.skewMs ?? DEFAULT_SKEW_MS;
57
57
  const capturedEntry = entry;
58
58
  const inFlight = (async () => {
59
- const { mintStoreCredentials } = await import("../seed-R2JK2YQK.js");
59
+ const { mintStoreCredentials } = await import("../seed-WJWCFPZL.js");
60
60
  const creds = await mintStoreCredentials({ ...ctx, config }, profile);
61
61
  capturedEntry.cached = { creds, validUntil: cacheFloor(creds, skewMs) };
62
62
  return creds;
@@ -6,66 +6,66 @@ import {
6
6
  diffVault,
7
7
  unsealDeks,
8
8
  withCargo
9
- } from "../chunk-QTWWZ25B.js";
9
+ } from "../chunk-UWRVDBDC.js";
10
10
  import {
11
11
  extractPartition,
12
12
  walkClosure
13
- } from "../chunk-M7VSXBUL.js";
13
+ } from "../chunk-SIACMXFK.js";
14
14
  import {
15
15
  createDeedOwner,
16
16
  isDeedVault,
17
17
  liberateVault,
18
18
  loadDeedMarker
19
- } from "../chunk-L3AM6EGU.js";
20
- import "../chunk-RJYPFCID.js";
21
- import "../chunk-BXHG26KN.js";
19
+ } from "../chunk-ISRAQIYY.js";
20
+ import "../chunk-I3D67XD7.js";
21
+ import "../chunk-7LWBD3NO.js";
22
22
  import {
23
23
  NO_CARGO,
24
24
  isQuorum,
25
25
  runDrainBarrier
26
- } from "../chunk-ZAZW5LLF.js";
26
+ } from "../chunk-WBFJZCDJ.js";
27
27
  import "../chunk-OTHHO3KI.js";
28
- import "../chunk-JPVJTTHU.js";
28
+ import "../chunk-SZFNO7L4.js";
29
29
  import {
30
30
  CustodyApi
31
- } from "../chunk-HZIIDYJV.js";
32
- import "../chunk-2VMCJUK6.js";
33
- import "../chunk-HRSEAGLI.js";
31
+ } from "../chunk-WG66ZPEV.js";
32
+ import "../chunk-XXONVJWA.js";
33
+ import "../chunk-5FRZ7YYU.js";
34
34
  import {
35
35
  fuseRetrieval
36
36
  } from "../chunk-AURFOK3D.js";
37
- import "../chunk-PNXJV4OS.js";
37
+ import "../chunk-BYX3AUXH.js";
38
38
  import {
39
39
  groupAndReduce,
40
40
  reduceRecords
41
- } from "../chunk-PWK3SSNB.js";
41
+ } from "../chunk-DXJXVWWE.js";
42
42
  import "../chunk-XZHEOSQ2.js";
43
43
  import "../chunk-ATL3ZVXT.js";
44
44
  import {
45
45
  readPath
46
46
  } from "../chunk-NSITFOCJ.js";
47
- import "../chunk-CW3VJARJ.js";
48
- import "../chunk-7JOXCSDU.js";
49
- import "../chunk-FFESJQ5A.js";
50
- import "../chunk-KMGAFLCK.js";
51
- import "../chunk-OCW3IM2F.js";
47
+ import "../chunk-U5ZDYJLQ.js";
48
+ import "../chunk-LZHIYH32.js";
49
+ import "../chunk-AK6EWGDO.js";
50
+ import "../chunk-GJ5TMHKC.js";
51
+ import "../chunk-3UIS6O6N.js";
52
52
  import {
53
53
  generateULID
54
54
  } from "../chunk-4AOERLTV.js";
55
55
  import "../chunk-SVLR4POP.js";
56
- import "../chunk-H27DIXOV.js";
56
+ import "../chunk-OGB2UTBC.js";
57
57
  import "../chunk-I7FD46FF.js";
58
- import "../chunk-47F6AI2K.js";
59
- import "../chunk-WUNRUSBJ.js";
60
- import "../chunk-DIVPOJPV.js";
58
+ import "../chunk-YLIGPHN4.js";
59
+ import "../chunk-6ZTPSVY7.js";
60
+ import "../chunk-FUE2KPKM.js";
61
61
  import "../chunk-PENPHA45.js";
62
- import "../chunk-IUQPNAGR.js";
63
- import "../chunk-AELW6OJZ.js";
64
- import "../chunk-DUUARUZI.js";
62
+ import "../chunk-OMXUQAZJ.js";
63
+ import "../chunk-PUGHLCBW.js";
64
+ import "../chunk-2LHPMFSR.js";
65
65
  import "../chunk-LP7BEXCT.js";
66
66
  import {
67
67
  sha256Hex
68
- } from "../chunk-O5QXH7U7.js";
68
+ } from "../chunk-RQQIB7CD.js";
69
69
  import "../chunk-IGNJOJEP.js";
70
70
  import {
71
71
  AdoptionStateError,
@@ -81,7 +81,7 @@ import {
81
81
  UnknownShardError,
82
82
  ValidationError,
83
83
  VaultTemplateNotFoundError
84
- } from "../chunk-PKUJ3JLQ.js";
84
+ } from "../chunk-HKANJAOP.js";
85
85
  import "../chunk-PZ5AY32C.js";
86
86
  export {
87
87
  AdoptionStateError,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  linkI18nVia
3
- } from "./chunk-CW3VJARJ.js";
3
+ } from "./chunk-U5ZDYJLQ.js";
4
4
 
5
5
  // src/via/i18n/dictionary.ts
6
6
  function dictKey(name, keysOrMap, opts) {
@@ -71,4 +71,4 @@ export {
71
71
  dictKey,
72
72
  staticDict
73
73
  };
74
- //# sourceMappingURL=chunk-QMJI5VHV.js.map
74
+ //# sourceMappingURL=chunk-22VRCUV2.js.map
@@ -1,16 +1,16 @@
1
1
  import {
2
2
  buildRecordAad,
3
3
  openEnvelopeJson
4
- } from "./chunk-DIVPOJPV.js";
4
+ } from "./chunk-FUE2KPKM.js";
5
5
  import {
6
6
  buildRecordEnvelope
7
7
  } from "./chunk-PENPHA45.js";
8
8
  import {
9
9
  encrypt
10
- } from "./chunk-O5QXH7U7.js";
10
+ } from "./chunk-RQQIB7CD.js";
11
11
  import {
12
12
  ConflictError
13
- } from "./chunk-PKUJ3JLQ.js";
13
+ } from "./chunk-HKANJAOP.js";
14
14
 
15
15
  // src/with-audit/attestation/signer.ts
16
16
  import { generateDocSigningKeyPair } from "@noy-db/attestation";
@@ -55,4 +55,4 @@ export {
55
55
  loadSigner,
56
56
  loadOrCreateSigner
57
57
  };
58
- //# sourceMappingURL=chunk-GWJJ5CK3.js.map
58
+ //# sourceMappingURL=chunk-23ODLABM.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  DuplicateBehaviorNameError
3
- } from "./chunk-PKUJ3JLQ.js";
3
+ } from "./chunk-HKANJAOP.js";
4
4
 
5
5
  // src/with-audit/guards/registry.ts
6
6
  var GuardRegistry = class {
@@ -141,4 +141,4 @@ var GuardRegistry = class {
141
141
  export {
142
142
  GuardRegistry
143
143
  };
144
- //# sourceMappingURL=chunk-WRGNEAUZ.js.map
144
+ //# sourceMappingURL=chunk-2DHEBIJA.js.map
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-LP7BEXCT.js";
6
6
  import {
7
7
  bufferToBase64
8
- } from "./chunk-O5QXH7U7.js";
8
+ } from "./chunk-RQQIB7CD.js";
9
9
 
10
10
  // src/kernel/enclave/classify/bidx.ts
11
11
  var subtle = globalThis.crypto.subtle;
@@ -66,4 +66,4 @@ export {
66
66
  mintBidxTag,
67
67
  computeBidxTarget
68
68
  };
69
- //# sourceMappingURL=chunk-DUUARUZI.js.map
69
+ //# sourceMappingURL=chunk-2LHPMFSR.js.map
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-Y2NBBT6K.js";
4
4
  import {
5
5
  sha256Hex
6
- } from "./chunk-O5QXH7U7.js";
6
+ } from "./chunk-RQQIB7CD.js";
7
7
 
8
8
  // src/with-shape/persisted-schemas/derive.ts
9
9
  function isZodSchema(value) {
@@ -79,4 +79,4 @@ export {
79
79
  isZod4Schema,
80
80
  derivePersistedSchema
81
81
  };
82
- //# sourceMappingURL=chunk-BPLSGN4X.js.map
82
+ //# sourceMappingURL=chunk-2QN6NPV6.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  dekKey
3
- } from "./chunk-WUNRUSBJ.js";
3
+ } from "./chunk-6ZTPSVY7.js";
4
4
  import {
5
5
  TierNotGrantedError
6
- } from "./chunk-PKUJ3JLQ.js";
6
+ } from "./chunk-HKANJAOP.js";
7
7
 
8
8
  // src/with-party/team/tiers.ts
9
9
  function assertTierAccess(keyring, collection, tier) {
@@ -17,4 +17,4 @@ function assertTierAccess(keyring, collection, tier) {
17
17
  export {
18
18
  assertTierAccess
19
19
  };
20
- //# sourceMappingURL=chunk-OCW3IM2F.js.map
20
+ //# sourceMappingURL=chunk-3UIS6O6N.js.map
@@ -1,7 +1,10 @@
1
+ import {
2
+ validateProjectionLegs
3
+ } from "./chunk-LPVZDTQF.js";
1
4
  import {
2
5
  MaterializedViewConfigError,
3
6
  ValidationError
4
- } from "./chunk-PKUJ3JLQ.js";
7
+ } from "./chunk-HKANJAOP.js";
5
8
 
6
9
  // src/with-formula/materialized-views/with-materialized-view.ts
7
10
  function withMaterializedView(spec) {
@@ -134,6 +137,7 @@ function withMaterializedView(spec) {
134
137
  }
135
138
  seenAs.add(l.as);
136
139
  }
140
+ validateProjectionLegs(spec.name, spec.projection);
137
141
  if (Array.isArray(spec.groupBy) && spec.groupBy.length === 0) {
138
142
  throw new MaterializedViewConfigError(
139
143
  `withMaterializedView "${spec.name}": groupBy must not be an empty array \u2014 omit it or provide at least one field name`
@@ -177,4 +181,4 @@ function withMaterializedView(spec) {
177
181
  export {
178
182
  withMaterializedView
179
183
  };
180
- //# sourceMappingURL=chunk-MBZFAJKM.js.map
184
+ //# sourceMappingURL=chunk-3ZOER5GD.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/with-formula/materialized-views/with-materialized-view.ts"],"sourcesContent":["import { MaterializedViewConfigError, ValidationError } from '../../kernel/errors.js'\nimport type { MaterializedViewSpec, MaterializedViewStrategy } from './types.js'\nimport { validateProjectionLegs } from './projection-legs.js' // #1140\n\n/**\n * Register a materialized view: a declared query whose result is\n * persisted as a queryable collection and kept fresh as sources\n * change. Writes go through the standard `Collection.put` pipeline;\n * refresh-driven deletes route through `Collection._internalDelete` so\n * user `onDelete` guards on the output collection aren't tripped by\n * housekeeping.\n *\n * Three registration modes:\n * - **single-source** — declare `query: (db) => Query<TRow>`; the\n * dependency analyzer derives source collections from the plan.\n * - **UNION** — declare `unionSources: [{ collection, map }, ...]`\n * plus optional `groupBy` + `aggregate`; the executor reads each\n * arm, maps to the unified row shape, concatenates, then groups\n * and aggregates.\n * - **projection** (#810) — declare `projection: { source, joins,\n * map }`; one output row per primary record, enriched with\n * forward FK legs and reverse \"collect\" legs before `map` runs.\n *\n * The three modes are mutually exclusive — exactly one of `query` /\n * `unionSources` / `projection` must be set at registration time.\n *\n * See design-history/2026-05-20-dim14-mv-v2-design.md (single-source v2),\n * design-history/2026-05-21-dim14-mv-multikey-and-union.md (UNION),\n * and design-history/2026-07-25-join-projection-mv-design.md (projection).\n */\nexport function withMaterializedView<TRow extends Record<string, unknown>>(\n spec: MaterializedViewSpec<TRow>,\n): MaterializedViewStrategy {\n if (!spec.name || spec.name.length === 0) {\n throw new ValidationError('withMaterializedView: name is required')\n }\n // Mutual exclusion: exactly one of the three forms must be declared.\n const declaredForms = [spec.query, spec.unionSources, spec.projection]\n .filter((f) => f !== undefined).length\n if (declaredForms > 1) {\n throw new MaterializedViewConfigError(\n 'query, unionSources, and projection are mutually exclusive — pick one',\n )\n }\n if (declaredForms === 0) {\n throw new MaterializedViewConfigError(\n 'strategy must declare exactly one of query, unionSources, or projection',\n )\n }\n if (spec.query !== undefined && typeof spec.query !== 'function') {\n throw new ValidationError('withMaterializedView: query must be a function returning a Query<T>')\n }\n // UNION-form invariants.\n if (spec.unionSources) {\n // A single arm is a deliberate shape: map→group→aggregate over\n // ONE collection with a COMPUTED bucket key (e.g. month sliced from a\n // date field) — something the query form's stored-field groupBy cannot\n // express. The executor and dependency analyzer are arm-count-agnostic.\n if (spec.unionSources.length < 1) {\n throw new MaterializedViewConfigError(\n 'unionSources requires at least 1 source collection',\n )\n }\n const seen = new Set<string>()\n for (const s of spec.unionSources) {\n if (typeof s?.collection !== 'string' || s.collection.length === 0) {\n throw new MaterializedViewConfigError(\n 'each unionSources entry must declare a non-empty `collection` string',\n )\n }\n if (typeof s.map !== 'function') {\n throw new MaterializedViewConfigError(\n `unionSources entry for \"${s.collection}\" is missing a \\`map\\` function`,\n )\n }\n if (seen.has(s.collection)) {\n throw new MaterializedViewConfigError(\n `unionSources must reference distinct collections (duplicate: \"${s.collection}\")`,\n )\n }\n seen.add(s.collection)\n }\n if (Array.isArray(spec.groupBy) && spec.groupBy.length === 0) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": groupBy must not be an empty array — omit it or provide at least one field name`,\n )\n }\n if (spec.aggregate && !spec.groupBy) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": UNION strategy with aggregate requires groupBy — `\n + `use groupBy to declare the bucketing keys, or remove aggregate for a pure dedup MV`,\n )\n }\n // `moneyFields` only has meaning when there's an aggregate to\n // money-rewrite — it keys reducer outputs, so declaring it without\n // `aggregate` is a no-op config mistake.\n if (spec.moneyFields && !spec.aggregate) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": moneyFields requires aggregate — `\n + `moneyFields rewrites sum/min/max reducers over money output fields, `\n + `so it is meaningless without an aggregate spec`,\n )\n }\n // Per-arm joins resolve right-side collections that the union\n // dependency set (built from arm `collection`s alone) does NOT\n // include. The consumer must list those right-side collections in\n // `sources` so writes to them trigger MV refresh.\n if (spec.unionSources.some(s => s.join && s.join.length > 0) && (!spec.sources || spec.sources.length === 0)) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": a unionSources arm declares join(s) but `\n + `no \\`sources\\` are listed — declare sources: [...] with the right-side `\n + `(join-target) collection names so writes to them trigger MV refresh`,\n )\n }\n if (spec.predicates) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": predicates are not supported on UNION strategies — `\n + `UNION mode does not use a Query<T> chain, so .wherePredicate() cannot fire. `\n + `Use the query() form, or open an issue if per-arm predicates are needed`,\n )\n }\n }\n // Projection-form invariants (#810). Shape checks only — the\n // semantic ref() check on collect legs (the `on` field must carry a\n // ref() targeting the projection source) runs at first\n // materialization, parity with join-time ref errors.\n if (spec.projection) {\n const projection = spec.projection\n if (typeof projection.source !== 'string' || projection.source.length === 0) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": projection.source must be a non-empty collection name`,\n )\n }\n if (typeof projection.map !== 'function') {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": projection is missing a \\`map\\` function`,\n )\n }\n if (!Array.isArray(projection.joins) || projection.joins.length < 1) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": projection.joins must declare at least 1 leg — `\n + `a leg-less single-source MV is the query() form's job`,\n )\n }\n const seenAs = new Set<string>()\n for (const leg of projection.joins) {\n const l = leg as { field?: unknown; collect?: unknown; on?: unknown; as?: unknown }\n const isForward = l.field !== undefined\n const isCollect = l.collect !== undefined\n if (isForward && isCollect) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": a projection leg cannot declare both \\`field\\` `\n + `(forward) and \\`collect\\` (reverse) — split it into two legs`,\n )\n }\n if (!isForward && !isCollect) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": each projection leg must declare either \\`field\\` `\n + `(forward FK) or \\`collect\\` (reverse one-to-many)`,\n )\n }\n if (isForward && (typeof l.field !== 'string' || l.field.length === 0)) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": a forward projection leg must declare a non-empty \\`field\\``,\n )\n }\n if (isCollect) {\n if (typeof l.collect !== 'string' || l.collect.length === 0) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": a collect projection leg must declare a non-empty \\`collect\\` collection name`,\n )\n }\n if (typeof l.on !== 'string' || l.on.length === 0) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": collect leg for \"${l.collect}\" must declare a non-empty \\`on\\` FK field`,\n )\n }\n }\n if (typeof l.as !== 'string' || l.as.length === 0) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": each projection leg must declare a non-empty \\`as\\` alias`,\n )\n }\n if (seenAs.has(l.as)) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": projection legs must attach under distinct \\`as\\` aliases (duplicate: \"${l.as}\")`,\n )\n }\n seenAs.add(l.as)\n }\n // #1140 — `from` wiring, checked here with the rest of the leg shape rather\n // than at vault open: it is pure configuration, so the earliest failure is\n // the best one. Owned by `projection-legs.ts` because the executor and the\n // registry both walk the same graph.\n validateProjectionLegs(spec.name, spec.projection)\n // Post-map grouping invariants — same rules as UNION (the mapped\n // stream feeds the same shared groupAndReduce tail).\n if (Array.isArray(spec.groupBy) && spec.groupBy.length === 0) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": groupBy must not be an empty array — omit it or provide at least one field name`,\n )\n }\n if (spec.aggregate && !spec.groupBy) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": projection strategy with aggregate requires groupBy — `\n + `use groupBy to declare the bucketing keys, or remove aggregate for a row-per-primary-record MV`,\n )\n }\n if (spec.moneyFields && !spec.aggregate) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": moneyFields requires aggregate — `\n + `moneyFields rewrites sum/min/max reducers over money output fields, `\n + `so it is meaningless without an aggregate spec`,\n )\n }\n if (spec.predicates) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": predicates are not supported on projection strategies — `\n + `projection mode does not use a Query<T> chain, so .wherePredicate() cannot fire. `\n + `Filter inside projection.map (return null to omit) instead`,\n )\n }\n }\n // i18nLocale + i18nFields drive compute-time i18n resolution of group-key\n // i18nText fields before bucketing — UNION mode (resolved on the unified rows)\n // AND query mode (resolved in GroupedReduction.run before groupAndReduce).\n // i18nLocale without i18nFields cannot resolve anything, so reject it early.\n if (spec.i18nLocale !== undefined && spec.i18nFields === undefined) {\n throw new MaterializedViewConfigError(\n `withMaterializedView \"${spec.name}\": i18nLocale requires i18nFields — `\n + `declare the i18nText descriptors of the group-key fields so they can be `\n + `resolved at the mv layer before bucketing.`,\n )\n }\n if (typeof spec.rowKey !== 'function') {\n throw new ValidationError('withMaterializedView: rowKey is required (no default; see spec § Type surface)')\n }\n if (spec.refresh !== 'eager' && spec.refresh !== 'lazy' && spec.refresh !== 'manual') {\n throw new ValidationError(\n `withMaterializedView: refresh must be 'eager' | 'lazy' | 'manual', got \"${String(spec.refresh)}\"`,\n )\n }\n return {\n __noydb_strategy: 'materialized-view',\n spec,\n }\n}\n"],"mappings":"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","names":[]}
@@ -5,7 +5,7 @@ import {
5
5
  import {
6
6
  FieldNotQueryableError,
7
7
  IndexRequiredError
8
- } from "./chunk-PKUJ3JLQ.js";
8
+ } from "./chunk-HKANJAOP.js";
9
9
 
10
10
  // src/with-lookup/indexing/strategy.ts
11
11
  var NO_INDEXING = {
@@ -534,4 +534,4 @@ export {
534
534
  PersistedCollectionIndex,
535
535
  LazyQuery
536
536
  };
537
- //# sourceMappingURL=chunk-3TWEXEKX.js.map
537
+ //# sourceMappingURL=chunk-4UZDDS4S.js.map
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-PENPHA45.js";
4
4
  import {
5
5
  ValidationError
6
- } from "./chunk-PKUJ3JLQ.js";
6
+ } from "./chunk-HKANJAOP.js";
7
7
 
8
8
  // src/with-party/directory/cover/custom.ts
9
9
  var CUSTOM_KEY_PATTERN = /^[a-z0-9]+([.-][a-z0-9]+)+$/i;
@@ -230,4 +230,4 @@ export {
230
230
  resolveLocale,
231
231
  pickLocale
232
232
  };
233
- //# sourceMappingURL=chunk-HRSEAGLI.js.map
233
+ //# sourceMappingURL=chunk-5FRZ7YYU.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  ValidationError
3
- } from "./chunk-PKUJ3JLQ.js";
3
+ } from "./chunk-HKANJAOP.js";
4
4
 
5
5
  // src/with-formula/derivations/with-derivation.ts
6
6
  function withDerivation(spec) {
@@ -126,4 +126,4 @@ export {
126
126
  withDerivation,
127
127
  withRollup
128
128
  };
129
- //# sourceMappingURL=chunk-F3BICEMK.js.map
129
+ //# sourceMappingURL=chunk-5MU7PUNA.js.map