scip-query 0.20.0 → 0.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +69 -0
- package/README.md +255 -884
- package/dist/augment-vue-worker.js +1 -1
- package/dist/by-kind-CI3O6PQG.js +2 -0
- package/dist/call-graph-6QTUTXH7.js +2 -0
- package/dist/call-graph-evidence-lZa2dwQA.d.ts +11 -0
- package/dist/change-analysis-types-CCtoCHbC.d.ts +9 -0
- package/dist/chunk-26CT72HM.js +2 -0
- package/dist/{chunk-7PIO7NKH.js → chunk-2COFMIVK.js} +2 -2
- package/dist/chunk-2H4IAJHO.js +2 -0
- package/dist/chunk-2I3RSUWX.js +16 -0
- package/dist/chunk-2RP27XLR.js +2 -0
- package/dist/chunk-2ZBMOQGG.js +3 -0
- package/dist/{chunk-HX4GQPZP.js → chunk-32A42O5B.js} +3 -3
- package/dist/chunk-35ELD3RM.js +2 -0
- package/dist/chunk-35IW3P4H.js +2 -0
- package/dist/{chunk-DQGFVPUV.js → chunk-3653GTR7.js} +3 -3
- package/dist/chunk-3EX7DNBC.js +2 -0
- package/dist/chunk-3FQ3KMCD.js +2 -0
- package/dist/{chunk-5E4WNAVD.js → chunk-3PII3JI5.js} +2 -2
- package/dist/chunk-3TNRNKAT.js +2 -0
- package/dist/chunk-3VLJ2DCA.js +2 -0
- package/dist/{chunk-XSRF6Q77.js → chunk-46JLFIGA.js} +2 -2
- package/dist/chunk-4DCKBY6T.js +5 -0
- package/dist/chunk-4EXFZP6H.js +2 -0
- package/dist/chunk-4IIMPWMR.js +29 -0
- package/dist/chunk-4ILHWBYF.js +2 -0
- package/dist/chunk-4N6QSEMZ.js +10 -0
- package/dist/chunk-4OE2JO6I.js +2 -0
- package/dist/{chunk-7BAVHKMJ.js → chunk-4S4DF62J.js} +9 -9
- package/dist/chunk-4UUCUASK.js +554 -0
- package/dist/chunk-5236NQV3.js +2 -0
- package/dist/chunk-54EOGFBR.js +2 -0
- package/dist/{chunk-LY4WC4AD.js → chunk-5H7IWVXJ.js} +2 -2
- package/dist/chunk-5IZTXSOL.js +117 -0
- package/dist/{chunk-AZJQQKDD.js → chunk-5SE323LF.js} +2 -2
- package/dist/chunk-5ZJH6DDE.js +2 -0
- package/dist/chunk-63MBA7EG.js +3 -0
- package/dist/chunk-6BJ7SOY7.js +2 -0
- package/dist/chunk-6GJAP4OE.js +2 -0
- package/dist/chunk-6IEVHGWG.js +26 -0
- package/dist/chunk-6SWA6B24.js +7 -0
- package/dist/chunk-6T7H2AFY.js +3 -0
- package/dist/chunk-73Z33VFI.js +4 -0
- package/dist/chunk-7COHFNJK.js +38 -0
- package/dist/chunk-7HU2IJ2T.js +3 -0
- package/dist/chunk-7IOAZRVL.js +60 -0
- package/dist/chunk-7KCZELVM.js +2 -0
- package/dist/chunk-7PPYXENX.js +2 -0
- package/dist/chunk-7TWP3MCP.js +2 -0
- package/dist/chunk-AA7K3XLM.js +21 -0
- package/dist/chunk-AJVMVE7X.js +7 -0
- package/dist/chunk-ANWGXPPN.js +4 -0
- package/dist/chunk-APLKXICZ.js +3 -0
- package/dist/{chunk-JDOEX4E6.js → chunk-AQDWTCDC.js} +2 -2
- package/dist/chunk-AUP6YI5M.js +2 -0
- package/dist/chunk-B7ECWJAZ.js +2 -0
- package/dist/{chunk-ZHXX42OH.js → chunk-BATIVRU2.js} +4 -4
- package/dist/chunk-BBEDPVPB.js +4 -0
- package/dist/chunk-BBWPOMGU.js +2 -0
- package/dist/chunk-BD6CV7PN.js +2 -0
- package/dist/{chunk-XKWKXZKW.js → chunk-BHE44MHT.js} +2 -2
- package/dist/chunk-BOJ5SVE2.js +2 -0
- package/dist/chunk-BZYSGZRK.js +2 -0
- package/dist/chunk-CA5RE6H7.js +2 -0
- package/dist/chunk-CKDOY6JA.js +2 -0
- package/dist/chunk-CN2WGM7D.js +2 -0
- package/dist/chunk-COTMS5KM.js +3 -0
- package/dist/chunk-CSDDOUA4.js +3 -0
- package/dist/chunk-CT5SI2I4.js +2 -0
- package/dist/chunk-D5EKVZPI.js +2 -0
- package/dist/{chunk-FKSELJQF.js → chunk-D5W4UZY5.js} +2 -2
- package/dist/{chunk-RUJURYSV.js → chunk-DEUGHURX.js} +2 -2
- package/dist/chunk-DHKBIOXF.js +7 -0
- package/dist/chunk-DMQ7ZKJG.js +81 -0
- package/dist/chunk-DMUGTKMD.js +2 -0
- package/dist/chunk-DOPCR5BY.js +2 -0
- package/dist/chunk-DRENNWRG.js +2 -0
- package/dist/chunk-E4EJBGDZ.js +2 -0
- package/dist/chunk-E7BJXRNV.js +2 -0
- package/dist/chunk-EA4SH4U5.js +5 -0
- package/dist/{chunk-L7AW2QB5.js → chunk-EKZRF57O.js} +2 -2
- package/dist/chunk-ELNRLMC5.js +29 -0
- package/dist/chunk-F4FNK44D.js +2 -0
- package/dist/chunk-F7WQ337U.js +308 -0
- package/dist/chunk-FEQIQ26E.js +2 -0
- package/dist/chunk-FGB567HK.js +23 -0
- package/dist/chunk-FHV7NMFU.js +29 -0
- package/dist/chunk-FN6EJM6Q.js +2 -0
- package/dist/chunk-FTSQNONX.js +2 -0
- package/dist/chunk-FUG6RPYY.js +6 -0
- package/dist/chunk-G2F6T5BV.js +2 -0
- package/dist/chunk-G6OGPXJW.js +9 -0
- package/dist/chunk-GFLTPNWV.js +3 -0
- package/dist/chunk-GTDP2SKQ.js +2 -0
- package/dist/chunk-H46QMB7E.js +2 -0
- package/dist/chunk-H5EXS3HM.js +2 -0
- package/dist/chunk-HEOMG7IM.js +8 -0
- package/dist/chunk-HG5YI7PV.js +2 -0
- package/dist/{chunk-7SQQWSY3.js → chunk-HGKEAP7F.js} +2 -2
- package/dist/chunk-HUZNZ3H2.js +2 -0
- package/dist/chunk-HWLCBKFE.js +2 -0
- package/dist/chunk-I3U2FN2T.js +13 -0
- package/dist/{chunk-JAYYFEQY.js → chunk-I7PFL5P3.js} +2 -2
- package/dist/{chunk-2HPVVXM5.js → chunk-ICHBVITH.js} +2 -2
- package/dist/chunk-ICUQONOG.js +38 -0
- package/dist/chunk-IDPLC3FI.js +5 -0
- package/dist/{chunk-A73XVBCR.js → chunk-IGKKTHJR.js} +2 -2
- package/dist/chunk-IOKWFRFQ.js +4 -0
- package/dist/chunk-IPAL6DP2.js +3 -0
- package/dist/chunk-IUJ3ZFEE.js +7 -0
- package/dist/chunk-IXJ26KJJ.js +16 -0
- package/dist/chunk-IYV2YBHM.js +2 -0
- package/dist/chunk-JVZNWJBH.js +2 -0
- package/dist/chunk-K5MZYZV7.js +3 -0
- package/dist/{chunk-3G66UZBH.js → chunk-KFK7GF5C.js} +2 -2
- package/dist/chunk-KTRGJLY7.js +18 -0
- package/dist/chunk-KW6B5OL4.js +2 -0
- package/dist/chunk-KWARB5FZ.js +2 -0
- package/dist/chunk-LHTT5C3Z.js +2 -0
- package/dist/chunk-LPGDO2XA.js +3 -0
- package/dist/chunk-LXLD46LH.js +21 -0
- package/dist/chunk-MEI3PTUK.js +2 -0
- package/dist/chunk-MJNV7OCG.js +5 -0
- package/dist/chunk-MO226P4Q.js +4 -0
- package/dist/{chunk-3CLX5EOX.js → chunk-MOBF2GH6.js} +2 -2
- package/dist/chunk-MXNGIEPU.js +3 -0
- package/dist/chunk-MYUKI5VN.js +4 -0
- package/dist/{chunk-TFRAYKN6.js → chunk-N5C65OFK.js} +2 -2
- package/dist/{chunk-PXY7F6Y4.js → chunk-O2RM7E7L.js} +5 -5
- package/dist/chunk-OFUBXBYX.js +3 -0
- package/dist/chunk-OFY4HTMI.js +2 -0
- package/dist/chunk-OIRWZIYL.js +38 -0
- package/dist/chunk-OIVZ7PW6.js +438 -0
- package/dist/chunk-ORBKAUCH.js +4 -0
- package/dist/chunk-OUB4J26T.js +2 -0
- package/dist/chunk-OVPS2ILI.js +20 -0
- package/dist/chunk-PHSPBQM6.js +5 -0
- package/dist/{chunk-JVYA47YU.js → chunk-PIZY2GX6.js} +2 -2
- package/dist/chunk-PNISDVYC.js +3 -0
- package/dist/chunk-PQOL42AW.js +2 -0
- package/dist/chunk-PUVZNFVY.js +11 -0
- package/dist/chunk-PZEI2TVL.js +4 -0
- package/dist/{chunk-ZK26BAQL.js → chunk-Q2J2VZZT.js} +2 -2
- package/dist/chunk-Q7HB7BFJ.js +2 -0
- package/dist/{chunk-ZTETIQ35.js → chunk-QBANU5BQ.js} +2 -2
- package/dist/chunk-QD7IFBCR.js +10 -0
- package/dist/chunk-QDCCHMVZ.js +2 -0
- package/dist/chunk-QLQBZOJH.js +3 -0
- package/dist/{chunk-PQCI4SQX.js → chunk-QXR5QPSF.js} +2 -2
- package/dist/chunk-R2MOKIVO.js +2 -0
- package/dist/{chunk-EN3O7VJA.js → chunk-RFWAUHVW.js} +2 -2
- package/dist/chunk-RGCJ4646.js +16 -0
- package/dist/{chunk-BPAPWKP6.js → chunk-S3RTPPLQ.js} +8 -8
- package/dist/chunk-S73HBCGI.js +11 -0
- package/dist/chunk-SDPA5DKN.js +210 -0
- package/dist/chunk-SEUJVWT2.js +3 -0
- package/dist/chunk-SF7X6QNW.js +2 -0
- package/dist/chunk-SKUMCCC5.js +2 -0
- package/dist/chunk-SSSJO4RG.js +2 -0
- package/dist/chunk-SWFAFA4G.js +49 -0
- package/dist/chunk-SYUNTKO2.js +2 -0
- package/dist/chunk-T6FRID7Y.js +3 -0
- package/dist/chunk-TGWNNMPF.js +3 -0
- package/dist/chunk-TM5XEDDR.js +4 -0
- package/dist/chunk-TNOHGHZQ.js +2 -0
- package/dist/chunk-U2GPTA5U.js +3 -0
- package/dist/{chunk-SXP2MBJH.js → chunk-U7DR7MJD.js} +2 -2
- package/dist/chunk-U7LRSQG6.js +3 -0
- package/dist/chunk-UL4VJUMD.js +2 -0
- package/dist/chunk-UNORWZIJ.js +16 -0
- package/dist/chunk-UQ7XPRWU.js +2 -0
- package/dist/{chunk-6SHPK5ZE.js → chunk-URMZLV2N.js} +2 -2
- package/dist/chunk-URTX2BEA.js +6 -0
- package/dist/chunk-UZFCZ7SJ.js +2 -0
- package/dist/{chunk-KMKTIO2G.js → chunk-V7LQZTTZ.js} +2 -2
- package/dist/chunk-VETXXOYU.js +3 -0
- package/dist/chunk-VGRUM7JI.js +3 -0
- package/dist/{chunk-WXZLAAWK.js → chunk-VNKYRJKN.js} +2 -2
- package/dist/chunk-VWLIOEEF.js +11 -0
- package/dist/chunk-WB6LGCFB.js +6 -0
- package/dist/{chunk-W4ETQAXM.js → chunk-WK4FD4PG.js} +2 -2
- package/dist/{chunk-O64IZ6UX.js → chunk-WKPZCQLI.js} +2 -2
- package/dist/chunk-WSG3DK5H.js +2 -0
- package/dist/chunk-WULAPQUD.js +38 -0
- package/dist/chunk-WZQFY5S7.js +4 -0
- package/dist/chunk-X434XZAI.js +2 -0
- package/dist/chunk-X7PJJYKX.js +29 -0
- package/dist/chunk-XDAUYDFT.js +2 -0
- package/dist/chunk-XITQLISP.js +2 -0
- package/dist/chunk-XRXCANFQ.js +4 -0
- package/dist/chunk-XVDMJMES.js +3 -0
- package/dist/chunk-XXJ7WL3F.js +35 -0
- package/dist/chunk-Y4XQ7LES.js +9 -0
- package/dist/chunk-YIEFEPG6.js +16 -0
- package/dist/chunk-YRVERHJR.js +49 -0
- package/dist/{chunk-CJST5ETY.js → chunk-YUFWLWIC.js} +2 -2
- package/dist/chunk-YUKYB54I.js +1 -0
- package/dist/chunk-Z3GCK3PD.js +3 -0
- package/dist/chunk-ZBNL3QCY.js +4 -0
- package/dist/chunk-ZD3Z54IW.js +2 -0
- package/dist/chunk-ZDVDSDFG.js +4 -0
- package/dist/{chunk-32LVLCLN.js → chunk-ZHSARYVS.js} +3 -3
- package/dist/{chunk-BDCC2NPY.js → chunk-ZW44MCJM.js} +2 -2
- package/dist/{chunk-N5W4YZMK.js → chunk-ZYREOING.js} +2 -2
- package/dist/cli-main.js +8 -0
- package/dist/cli.js +1 -3
- package/dist/code-CczEvHui.d.ts +121 -0
- package/dist/code-EQL6ZBLH.js +2 -0
- package/dist/code-result-json-6E4J6LGZ.js +2 -0
- package/dist/command-descriptors-QH3G2OVD.js +346 -0
- package/dist/{config-types-jVM3D7MA.d.ts → config-types-Cm-VSEBb.d.ts} +189 -23
- package/dist/dataflow-2BLMUZBP.js +2 -0
- package/dist/{db-B5PM5yNk.d.ts → db-LKJXAlNS.d.ts} +1 -1
- package/dist/dependence-slice-MGAJDZXB.js +2 -0
- package/dist/deps-GQMUYVKW.js +2 -0
- package/dist/direct-navigation-6RUJKLAV.js +3 -0
- package/dist/entry-map-V2NQP5JU.js +2 -0
- package/dist/exploration-topology-BG4v30HZ.d.ts +256 -0
- package/dist/file-dep-graph-Bqg3t3Px.d.ts +4 -0
- package/dist/file-kind-BKCVMNUf.d.ts +10 -0
- package/dist/files-VM53I4IU.js +2 -0
- package/dist/graph-evidence-CbUPCSKV.d.ts +126 -0
- package/dist/graph-exploration-contract-CqDsnPQL.d.ts +7 -0
- package/dist/{health-Do5TKSJI.d.ts → health-Wl5G_LRt.d.ts} +33 -34
- package/dist/hierarchy-D553WRSZ.js +2 -0
- package/dist/imports-DOZAJWLW.js +2 -0
- package/dist/index.d.ts +4 -31
- package/dist/index.js +1 -1
- package/dist/members-HE67475K.js +2 -0
- package/dist/methods-K5JK4PPH.js +2 -0
- package/dist/next-anchor-candidates-BwMczMvX.d.ts +90 -0
- package/dist/output-continuation-command-LKBUTNRL.js +3 -0
- package/dist/output-pagination-VAWOGX4R.js +19 -0
- package/dist/postinstall.js +1 -1
- package/dist/project-reindex-4ARU6QCM.js +3 -0
- package/dist/queries/affected.d.ts +22 -4
- package/dist/queries/affected.js +1 -1
- package/dist/queries/anchors.d.ts +123 -0
- package/dist/queries/anchors.js +2 -0
- package/dist/queries/architecture.d.ts +3 -2
- package/dist/queries/architecture.js +1 -1
- package/dist/queries/bottlenecks.d.ts +26 -7
- package/dist/queries/bottlenecks.js +1 -1
- package/dist/queries/by-kind.d.ts +2 -2
- package/dist/queries/by-kind.js +1 -1
- package/dist/queries/call-graph.d.ts +17 -3
- package/dist/queries/call-graph.js +1 -1
- package/dist/queries/change-surface.d.ts +2 -2
- package/dist/queries/change-surface.js +1 -1
- package/dist/queries/cleanup-plan.d.ts +2 -2
- package/dist/queries/cleanup-plan.js +1 -1
- package/dist/queries/co-change.d.ts +2 -2
- package/dist/queries/co-change.js +1 -1
- package/dist/queries/code.d.ts +5 -26
- package/dist/queries/code.js +1 -1
- package/dist/queries/complexity-hotspots.d.ts +2 -2
- package/dist/queries/complexity-hotspots.js +1 -1
- package/dist/queries/complexity.d.ts +2 -2
- package/dist/queries/complexity.js +1 -1
- package/dist/queries/context.d.ts +145 -0
- package/dist/queries/context.js +2 -0
- package/dist/queries/convergence.d.ts +2 -2
- package/dist/queries/convergence.js +1 -1
- package/dist/queries/coupling.d.ts +8 -3
- package/dist/queries/coupling.js +1 -1
- package/dist/queries/cycles.d.ts +34 -7
- package/dist/queries/cycles.js +1 -1
- package/dist/queries/dataflow.d.ts +40 -14
- package/dist/queries/dataflow.js +1 -1
- package/dist/queries/dead.d.ts +2 -2
- package/dist/queries/dead.js +1 -1
- package/dist/queries/decorative-checkers.d.ts +3 -3
- package/dist/queries/decorative-checkers.js +1 -1
- package/dist/queries/deep-chains.d.ts +4 -38
- package/dist/queries/deep-chains.js +1 -1
- package/dist/queries/dependence-slice.d.ts +47 -0
- package/dist/queries/dependence-slice.js +2 -0
- package/dist/queries/dependency-depth.d.ts +49 -0
- package/dist/queries/dependency-depth.js +2 -0
- package/dist/queries/deps.d.ts +4 -2
- package/dist/queries/deps.js +1 -1
- package/dist/queries/diff-impact.d.ts +3 -3
- package/dist/queries/diff-impact.js +1 -1
- package/dist/queries/doc-drift.d.ts +4 -4
- package/dist/queries/doc-drift.js +1 -1
- package/dist/queries/drift.d.ts +2 -2
- package/dist/queries/drift.js +1 -1
- package/dist/queries/duplicate-bodies.d.ts +2 -2
- package/dist/queries/duplicate-bodies.js +1 -1
- package/dist/queries/entry-map.d.ts +121 -0
- package/dist/queries/entry-map.js +2 -0
- package/dist/queries/evidence.d.ts +70 -0
- package/dist/queries/evidence.js +2 -0
- package/dist/queries/extract-candidates.d.ts +2 -2
- package/dist/queries/extract-candidates.js +1 -1
- package/dist/queries/fan.d.ts +18 -5
- package/dist/queries/fan.js +1 -1
- package/dist/queries/files.d.ts +2 -2
- package/dist/queries/files.js +1 -1
- package/dist/queries/health.d.ts +4 -3
- package/dist/queries/health.js +1 -1
- package/dist/queries/hierarchy.d.ts +5 -3
- package/dist/queries/hierarchy.js +1 -1
- package/dist/queries/hotspots.d.ts +11 -5
- package/dist/queries/hotspots.js +1 -1
- package/dist/queries/imports.d.ts +2 -2
- package/dist/queries/imports.js +1 -1
- package/dist/queries/incomplete-migration.d.ts +4 -4
- package/dist/queries/incomplete-migration.js +1 -1
- package/dist/queries/index.d.ts +56 -136
- package/dist/queries/index.js +1 -1
- package/dist/queries/isolated.d.ts +2 -2
- package/dist/queries/isolated.js +1 -1
- package/dist/queries/locality-candidates.d.ts +2 -2
- package/dist/queries/locality-candidates.js +1 -1
- package/dist/queries/members.d.ts +2 -2
- package/dist/queries/members.js +1 -1
- package/dist/queries/methods.d.ts +2 -2
- package/dist/queries/methods.js +1 -1
- package/dist/queries/not-implemented.d.ts +3 -3
- package/dist/queries/not-implemented.js +1 -1
- package/dist/queries/outline.d.ts +2 -2
- package/dist/queries/outline.js +1 -1
- package/dist/queries/passthrough-candidates.d.ts +5 -9
- package/dist/queries/passthrough-candidates.js +1 -1
- package/dist/queries/plan-context.d.ts +27 -64
- package/dist/queries/plan-context.js +1 -1
- package/dist/queries/react-component-duplicates.d.ts +2 -2
- package/dist/queries/react-component-duplicates.js +1 -1
- package/dist/queries/react-hook-candidates.d.ts +2 -2
- package/dist/queries/react-hook-candidates.js +1 -1
- package/dist/queries/react-large-component-pressure.d.ts +2 -2
- package/dist/queries/react-large-component-pressure.js +1 -1
- package/dist/queries/recent-duplicates.d.ts +2 -2
- package/dist/queries/recent-duplicates.js +1 -1
- package/dist/queries/redundant-reexports.d.ts +2 -2
- package/dist/queries/redundant-reexports.js +1 -1
- package/dist/queries/reference-neighborhood.d.ts +4 -0
- package/dist/queries/reference-neighborhood.js +2 -0
- package/dist/queries/reference-reachability.d.ts +48 -0
- package/dist/queries/reference-reachability.js +2 -0
- package/dist/queries/refs.d.ts +2 -2
- package/dist/queries/refs.js +1 -1
- package/dist/queries/self-audit.d.ts +2 -2
- package/dist/queries/self-audit.js +1 -1
- package/dist/queries/similar-chains.d.ts +2 -2
- package/dist/queries/similar-chains.js +1 -1
- package/dist/queries/similar-files.d.ts +2 -2
- package/dist/queries/similar-files.js +1 -1
- package/dist/queries/similar-signatures.d.ts +2 -2
- package/dist/queries/similar-signatures.js +1 -1
- package/dist/queries/similar.d.ts +2 -2
- package/dist/queries/similar.js +1 -1
- package/dist/queries/slice.d.ts +3 -36
- package/dist/queries/slice.js +1 -1
- package/dist/queries/source-inspection.d.ts +209 -0
- package/dist/queries/source-inspection.js +2 -0
- package/dist/queries/source-search.d.ts +13 -0
- package/dist/queries/source-search.js +2 -0
- package/dist/queries/stale-abstractions.d.ts +2 -2
- package/dist/queries/stale-abstractions.js +1 -1
- package/dist/queries/stats.d.ts +2 -2
- package/dist/queries/surface.d.ts +13 -4
- package/dist/queries/surface.js +1 -1
- package/dist/queries/symbols.d.ts +2 -2
- package/dist/queries/symbols.js +1 -1
- package/dist/queries/system-map.d.ts +449 -0
- package/dist/queries/system-map.js +2 -0
- package/dist/queries/system.d.ts +5 -3
- package/dist/queries/system.js +1 -1
- package/dist/queries/test-quality.d.ts +2 -2
- package/dist/queries/test-quality.js +1 -1
- package/dist/queries/trace.d.ts +47 -3
- package/dist/queries/trace.js +1 -1
- package/dist/queries/twin-ab.d.ts +3 -3
- package/dist/queries/twin-ab.js +1 -1
- package/dist/queries/twin-drift.d.ts +3 -3
- package/dist/queries/twin-drift.js +1 -1
- package/dist/queries/unused-imports.d.ts +2 -2
- package/dist/queries/unused-imports.js +1 -1
- package/dist/queries/unused-params.d.ts +2 -2
- package/dist/queries/unused-params.js +1 -1
- package/dist/queries/value-flow.d.ts +43 -0
- package/dist/queries/value-flow.js +2 -0
- package/dist/queries/vue-component-duplicates.d.ts +2 -2
- package/dist/queries/vue-component-duplicates.js +1 -1
- package/dist/queries/vue-composable-candidates.d.ts +2 -2
- package/dist/queries/vue-composable-candidates.js +1 -1
- package/dist/queries/vue-large-view-pressure.d.ts +2 -2
- package/dist/queries/vue-large-view-pressure.js +1 -1
- package/dist/queries/wrapper-candidates.d.ts +2 -2
- package/dist/queries/wrapper-candidates.js +1 -1
- package/dist/query-service-fastpath.js +6 -0
- package/dist/query-service-server.js +5 -0
- package/dist/refs-NBHKL4UQ.js +2 -0
- package/dist/refs-pagination-BBVTIHMH.js +2 -0
- package/dist/reindex-worker.js +27 -45
- package/dist/reindex.d.ts +62 -42
- package/dist/reindex.js +32 -33
- package/dist/repository-text-C0Q8VYdN.d.ts +19 -0
- package/dist/runtime.d.ts +286 -7
- package/dist/runtime.js +4 -3
- package/dist/rust-semantic-session-server.js +1 -1
- package/dist/rust-semantic-session-worker.js +1 -1
- package/dist/rust-semantic-worker.js +1 -1
- package/dist/{scip-cli-BnEwZRLJ.d.ts → scip-cli-CppzF5MK.d.ts} +33 -2
- package/dist/slice-U6S6LBSB.js +2 -0
- package/dist/source-search-types-Dwz8KeuW.d.ts +79 -0
- package/dist/source-snippet-_wrcgmZc.d.ts +15 -0
- package/dist/stats-OOJ74B32.js +2 -0
- package/dist/surface-C7SS5CDQ.js +2 -0
- package/dist/symbol-resolution-3FVEKDTJ.js +2 -0
- package/dist/system-6K2NOO5C.js +2 -0
- package/dist/trace-II5K2TMH.js +2 -0
- package/dist/typescript-mailbox-worker.js +1 -1
- package/dist/value-flow-MKFUUE5B.js +2 -0
- package/dist/watch-server.js +3 -2
- package/docs/AGENT_GUIDE.md +133 -476
- package/docs/AI_FAILURE_MODES.md +30 -301
- package/docs/API.md +1 -1
- package/docs/API_EVOLUTION.md +6 -0
- package/docs/CLI_JSON_OUTPUT.md +207 -29
- package/docs/COMMAND_REFERENCE.md +255 -154
- package/docs/CONFIGURATION_WRITE_SAFETY.md +14 -13
- package/docs/DETECTOR_EVIDENCE_CONTRACTS.md +84 -0
- package/docs/DETECTOR_GUIDE.md +46 -138
- package/docs/DURABILITY.md +7 -1
- package/docs/INDEX_GENERATIONS.md +6 -0
- package/docs/LOCK_PROTOCOL.md +8 -0
- package/docs/REINDEX_METADATA_COMPATIBILITY.md +13 -3
- package/docs/SECURITY_MODEL.md +39 -42
- package/docs/accuracy-audit-checklist.md +4 -0
- package/docs/accuracy-hardening-goal.md +9 -2
- package/docs/analyzer-inventory.md +59 -264
- package/docs/analyzer-validation-protocol.md +62 -170
- package/docs/architecture-coherence-vision.md +18 -12
- package/docs/locality-analyzer-design.md +1 -1
- package/docs/schemas/cli-json-envelope.schema.json +212 -27
- package/docs/schemas/cli-json-export-receipt.schema.json +25 -0
- package/docs/schemas/cli-output-page.schema.json +1 -1
- package/docs/schemas/observation-receipt.schema.json +164 -0
- package/docs/schemas/project-config.schema.json +27 -45
- package/docs/schemas/suppression-record.schema.json +1 -34
- package/package.json +65 -8
- package/skills/concrete-plan/SKILL.md +8 -0
- package/skills/concrete-plan/agents/openai.yaml +4 -0
- package/skills/scip-explore/SKILL.md +3 -85
- package/skills/scip-explore/agents/openai.yaml +3 -3
- package/skills/scip-integrity-audit/SKILL.md +185 -0
- package/skills/scip-integrity-audit/agents/openai.yaml +4 -0
- package/skills/scip-plan/SKILL.md +67 -49
- package/skills/scip-plan/agents/openai.yaml +3 -3
- package/skills/scip-query/SKILL.md +77 -77
- package/skills/scip-query/agents/openai.yaml +3 -3
- package/skills/scip-setup/SKILL.md +10 -102
- package/skills/scip-setup/agents/openai.yaml +3 -3
- package/dist/chunk-26QA6FAI.js +0 -8
- package/dist/chunk-2KAZEZ6M.js +0 -2
- package/dist/chunk-3ORVDL3H.js +0 -2
- package/dist/chunk-46XGSFNI.js +0 -2
- package/dist/chunk-4MAK2HOY.js +0 -6
- package/dist/chunk-4TURLRL5.js +0 -16
- package/dist/chunk-4UQVNCQE.js +0 -2
- package/dist/chunk-55Q3WLZX.js +0 -2
- package/dist/chunk-5I5G2QOX.js +0 -3
- package/dist/chunk-6LDJQXAH.js +0 -2
- package/dist/chunk-6O5TICIZ.js +0 -3
- package/dist/chunk-7O5IKBTZ.js +0 -16
- package/dist/chunk-7S5E7KWT.js +0 -2
- package/dist/chunk-7WPLAODU.js +0 -5
- package/dist/chunk-AFHORGLH.js +0 -42
- package/dist/chunk-AIE7TFJW.js +0 -9
- package/dist/chunk-AQOFWNQJ.js +0 -1
- package/dist/chunk-B2PX5I6M.js +0 -2
- package/dist/chunk-B75HZHUP.js +0 -2
- package/dist/chunk-B7PBSLZN.js +0 -2
- package/dist/chunk-BBW6JFHN.js +0 -2
- package/dist/chunk-BNXCIFVY.js +0 -2
- package/dist/chunk-BS2NMXQZ.js +0 -4
- package/dist/chunk-C3KV2II6.js +0 -2
- package/dist/chunk-C43RDDP4.js +0 -20
- package/dist/chunk-DAFAHMNB.js +0 -42
- package/dist/chunk-DQLPXMH6.js +0 -8
- package/dist/chunk-EKZTZXHZ.js +0 -117
- package/dist/chunk-EW2NTSFA.js +0 -18
- package/dist/chunk-F3Z4OUDS.js +0 -8
- package/dist/chunk-FJH2NW7J.js +0 -66
- package/dist/chunk-FTFP6O3L.js +0 -11
- package/dist/chunk-FYLK2DEJ.js +0 -2
- package/dist/chunk-GH74ASD6.js +0 -11
- package/dist/chunk-GMXWZP2B.js +0 -2
- package/dist/chunk-GOUBFH5O.js +0 -3
- package/dist/chunk-HLF2TX6R.js +0 -2
- package/dist/chunk-HX7M4BDI.js +0 -30
- package/dist/chunk-HZ72SESS.js +0 -128
- package/dist/chunk-IB2N4FIY.js +0 -10
- package/dist/chunk-IZYYAFN5.js +0 -2
- package/dist/chunk-JFGGXWQF.js +0 -947
- package/dist/chunk-JN4NMBEX.js +0 -8
- package/dist/chunk-JW56N3KI.js +0 -4
- package/dist/chunk-JZ2OXNWB.js +0 -2
- package/dist/chunk-KFZNKUNT.js +0 -2
- package/dist/chunk-L5GJNV2T.js +0 -8
- package/dist/chunk-L7JDSCDF.js +0 -4
- package/dist/chunk-LU47HG23.js +0 -14
- package/dist/chunk-LVY7NPF7.js +0 -2
- package/dist/chunk-MKCDWWGV.js +0 -4
- package/dist/chunk-MNE7YG56.js +0 -2
- package/dist/chunk-MRXBEXSY.js +0 -26
- package/dist/chunk-MV7OWDUX.js +0 -2
- package/dist/chunk-NGEXCJJW.js +0 -11
- package/dist/chunk-NIW6JDC5.js +0 -29
- package/dist/chunk-PBUQFCNB.js +0 -16
- package/dist/chunk-POAVPHH7.js +0 -2
- package/dist/chunk-QZ4JVECJ.js +0 -2
- package/dist/chunk-RDO52JGY.js +0 -2
- package/dist/chunk-RJT3TUUZ.js +0 -2
- package/dist/chunk-RVLDN63O.js +0 -4
- package/dist/chunk-RXOXSKY3.js +0 -2
- package/dist/chunk-S7OYBOCK.js +0 -2
- package/dist/chunk-SMNXQT5Z.js +0 -3
- package/dist/chunk-SRAFT254.js +0 -2
- package/dist/chunk-T7YQSHPQ.js +0 -3
- package/dist/chunk-UJCOIXDY.js +0 -2
- package/dist/chunk-UJPRPGCO.js +0 -13
- package/dist/chunk-WCCFZ7V7.js +0 -113
- package/dist/chunk-WUPW3UN3.js +0 -3
- package/dist/chunk-X54AGLVX.js +0 -2
- package/dist/chunk-Y2MVPNKY.js +0 -5
- package/dist/chunk-YKUU5AIC.js +0 -3
- package/dist/chunk-YLCJLTPL.js +0 -2
- package/dist/chunk-YTQVETEO.js +0 -2
- package/dist/chunk-Z4N3MZYA.js +0 -38
- package/dist/chunk-ZJOOT3BG.js +0 -2
- package/dist/command-descriptors-DSS46KXI.js +0 -642
- package/dist/diff-gate-types-B0QYpDv1.d.ts +0 -11
- package/dist/direct-navigation-6YHV6IB5.js +0 -3
- package/dist/queries/diff-gate.d.ts +0 -253
- package/dist/queries/diff-gate.js +0 -2
- package/docs/COMMITTED_RECORD_COMPATIBILITY.md +0 -154
- package/docs/analyzer-validation-ledger.md +0 -516
- package/docs/schemas/outcome-event-record.schema.json +0 -95
- package/skills/_shared/SKILL.md +0 -101
- package/skills/_shared/agents/openai.yaml +0 -4
- package/skills/_shared/references/agent-contract-catalog.md +0 -105
- package/skills/_shared/references/command-catalog.md +0 -118
- package/skills/_shared/references/detector-precision-and-diffgate.md +0 -59
- package/skills/_shared/references/evidence-and-dead-code.md +0 -25
- package/skills/scip-audit/SKILL.md +0 -77
- package/skills/scip-audit/agents/openai.yaml +0 -4
- package/skills/scip-audit/references/claims.md +0 -98
- package/skills/scip-audit/references/cleanup.md +0 -100
- package/skills/scip-audit/references/directory.md +0 -222
- package/skills/scip-audit/references/frontend.md +0 -130
- package/skills/scip-audit/references/integrity.md +0 -154
- package/skills/scip-audit/references/maintainability.md +0 -162
- package/skills/scip-audit/references/twin-drift.md +0 -104
- package/skills/scip-diagnose/SKILL.md +0 -52
- package/skills/scip-diagnose/agents/openai.yaml +0 -4
- package/skills/scip-diagnose/references/debug.md +0 -117
- package/skills/scip-diagnose/references/probe-reachability.md +0 -77
- package/skills/scip-diagnose/references/root-cause.md +0 -145
- package/skills/scip-diagnose/references/triage.md +0 -119
- package/skills/scip-explore/references/diagrams.md +0 -40
- package/skills/scip-explore/references/language-playbook.md +0 -49
- package/skills/scip-improve/SKILL.md +0 -56
- package/skills/scip-improve/agents/openai.yaml +0 -4
- package/skills/scip-improve/references/cleanup-batches.md +0 -53
- package/skills/scip-improve/references/directory-moves.md +0 -53
- package/skills/scip-improve/references/doc-reconcile.md +0 -30
- package/skills/scip-improve/references/frontend-extraction.md +0 -39
- package/skills/scip-improve/references/maintainability-mechanism.md +0 -43
- package/skills/scip-improve/references/twin-drift.md +0 -35
- package/skills/scip-plan/references/api-impact.md +0 -19
- package/skills/scip-plan/references/conductor.md +0 -41
- package/skills/scip-plan/references/high-assurance.md +0 -43
- package/skills/scip-plan/references/hyper-optimization.md +0 -50
- package/skills/scip-plan/references/tla-model.md +0 -88
- package/skills/scip-setup/references/bootstrap-workflow.md +0 -119
- package/skills/scip-setup/references/language-verification.md +0 -61
- package/skills/scip-setup/references/lifecycle-commands.md +0 -119
- package/skills/scip-setup/references/per-repo-triage.md +0 -24
- package/skills/scip-verify/SKILL.md +0 -229
- package/skills/scip-verify/agents/openai.yaml +0 -4
- package/skills/scip-verify/references/calibrate-detectors.md +0 -170
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import{isAbsolute as ee,relative as qe}from"path";var g=class extends Error{constructor(r,n){super(`refusing unsafe project file path ${JSON.stringify(r)} (${n})`);this.relativePath=r;this.reason=n;this.name="UnsafeProjectPathError"}relativePath;reason;code="SCIP_QUERY_UNSAFE_PROJECT_PATH"};function T(e){return e.replace(/\\/g,"/").replace(/^\.\//,"")}function rr(e){return e.replace(/\\/g,"/")}function nr(e,t){return T(e)===T(t)}function G(e,t){let r=qe(e,t);return r===""||!r.startsWith("..")&&!ee(r)}function te(e){if(!e)throw new g(e,"empty-path");if(e.includes("\0"))throw new g(e,"nul-byte");if(ee(e)||/^[A-Za-z]:/.test(e)||e.startsWith("//")||e.startsWith("\\\\"))throw new g(e,"absolute-path");let t=T(e);if(t.split("/").some(n=>n===".."))throw new g(e,"parent-traversal");if(!t||t===".")throw new g(e,"empty-path");return t}function Ue(e,t,r=[]){let n=N(e);if(se.has(n)||r.some(o=>P(n,o))||t.some(o=>ae(n,o)))return"config";if(t.some(ue)&&/\.d\.(?:ts|mts|cts)$/.test(n.toLowerCase()))return"ambient";let i=ce(n);return t.some(o=>(de[o]??[]).includes(i))?"source":"other"}function or(e,t,r){let n=N(e);if(se.has(n)||r?.some(o=>P(n,o))||ae(n,t)||ue(t)&&/\.d\.(?:ts|mts|cts)$/.test(n.toLowerCase()))return!0;let i=ce(n);return(de[t]??[]).includes(i)}function sr(e){if(typeof e!="object"||e===null)return null;let t=e;return typeof t.version!="number"||!re(t.languages)||typeof t.pnpmWorkspaces!="boolean"||typeof t.typescriptProjectMode!="string"||!re(t.typescriptProjects)||t.clojureConfigPath!==void 0&&typeof t.clojureConfigPath!="string"||!Array.isArray(t.files)||!t.files.every(M)?null:t}function ar(e,t){let r=new Map((e?.files??[]).map(a=>[a.path,a])),n=new Map(t.files.map(a=>[a.path,a])),i=new Set([...r.keys(),...n.keys()]),o=[];for(let a of[...i].sort()){let u=r.get(a),c=n.get(a),l=Ue(a,t.languages);!u&&c?o.push({kind:"added",path:a,inputKind:l,after:c}):u&&!c?o.push({kind:"deleted",path:a,inputKind:l,before:u}):u&&c&&(u.hash!==c.hash||u.size!==c.size)&&o.push({kind:"modified",path:a,inputKind:l,before:u,after:c})}let s=new Set;return e||s.add("prior-snapshot-unavailable"),e&&e.version!==t.version&&s.add("snapshot-version-changed"),(ne(e?.files??[])||ne(t.files))&&s.add("duplicate-input-path"),[...e?.files??[],...t.files].some($e)&&s.add("unreadable-input"),{version:1,changes:o,projectIdentityChanged:e?!He(e,t):!0,uncertainty:[...s].sort()}}function re(e){return Array.isArray(e)&&e.every(t=>typeof t=="string")}function ne(e){return new Set(e.map(t=>t.path)).size!==e.length}function M(e){if(typeof e!="object"||e===null)return!1;let t=e;return typeof t.path=="string"&&typeof t.size=="number"&&Number.isFinite(t.size)&&typeof t.hash=="string"}function $e(e){return e.hash==="unreadable"||e.size<0}function He(e,t){return ie(e.languages,t.languages)&&e.pnpmWorkspaces===t.pnpmWorkspaces&&e.typescriptProjectMode===t.typescriptProjectMode&&ie(e.typescriptProjects,t.typescriptProjects)&&e.clojureConfigPath===t.clojureConfigPath}function ie(e,t){if(e.length!==t.length)return!1;let r=[...e].sort(),n=[...t].sort();return r.every((i,o)=>i===n[o])}var se=new Set([".scipquery.json"]),ze={typescript:["tsconfig.json"],javascript:["package.json"],java:["pom.xml","build.gradle"],scala:["build.sbt"],kotlin:["build.gradle.kts"],rust:["Cargo.toml"],python:["pyproject.toml","setup.py"],ruby:["Gemfile"],go:["go.mod"],cpp:["CMakeLists.txt","Makefile"],c:["CMakeLists.txt","Makefile"],csharp:["*.csproj","*.sln"],vb:["*.vbproj","*.sln"],dart:["pubspec.yaml"],php:["composer.json"],clojure:["deps.edn","project.clj","bb.edn","shadow-cljs.edn"]},Ve={typescript:["package.json","package-lock.json","pnpm-lock.yaml","yarn.lock","bun.lock","bun.lockb","tsconfig.*.json","jsconfig.json","jsconfig.*.json"],javascript:["package-lock.json","pnpm-lock.yaml","yarn.lock","bun.lock","bun.lockb","tsconfig.json","tsconfig.*.json","jsconfig.json","jsconfig.*.json"],java:["build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","gradle.lockfile","gradle-wrapper.properties"],scala:["plugins.sbt","build.properties"],kotlin:["pom.xml","build.gradle","settings.gradle","settings.gradle.kts","gradle.properties","gradle.lockfile","gradle-wrapper.properties"],rust:["Cargo.lock","rust-project.json","rust-toolchain","rust-toolchain.toml"],python:["setup.cfg","requirements*.txt","Pipfile","Pipfile.lock","poetry.lock","uv.lock"],ruby:["Gemfile.lock","gems.locked"],go:["go.sum","go.work","go.work.sum"],cpp:["compile_commands.json"],c:["compile_commands.json"],csharp:["Directory.Build.props","Directory.Build.targets","Directory.Packages.props","packages.lock.json","NuGet.Config","global.json"],vb:["Directory.Build.props","Directory.Build.targets","Directory.Packages.props","packages.lock.json","NuGet.Config","global.json"],dart:["pubspec.lock","analysis_options.yaml"],php:["composer.lock"],clojure:[]},oe=new Map;function ae(e,t){return ze[t].some(r=>P(e,r))||Ve[t].some(r=>P(e,r))}function P(e,t){let r=N(t).replace(/^\.\//,"");if(!r)return!1;let n=e.split("/").at(-1)??e,i=r.includes("/")?e:n;if(!r.includes("*")&&!r.includes("?"))return i===r;let o=oe.get(r);if(!o){let s=r.replace(/[.+^${}()|[\]\\]/g,"\\$&").replace(/\*/g,"[^/]*").replace(/\?/g,"[^/]");o=new RegExp(`^${s}$`),oe.set(r,o)}return o.test(i)}function N(e){return e.replaceAll("\\","/").replace(/^\.\//,"")}function ce(e){return e.includes(".")?`.${e.split(".").at(-1).toLowerCase()}`:""}function ue(e){return e==="typescript"||e==="javascript"}var de={typescript:[".ts",".tsx",".mts",".cts"],javascript:[".js",".jsx",".mjs",".cjs",".vue"],java:[".java"],scala:[".scala"],kotlin:[".kt",".kts"],rust:[".rs"],python:[".py",".pyi"],ruby:[".rb"],go:[".go"],cpp:[".cc",".cpp",".cxx",".hpp",".hh",".hxx"],c:[".c",".h"],csharp:[".cs"],vb:[".vb"],dart:[".dart"],php:[".php"],clojure:[".clj",".cljs",".cljc"]};function y(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function pe(e){return typeof e=="string"&&Number.isFinite(Date.parse(e))}function ur(e){return typeof e=="string"&&e.length>0}function dr(e){return typeof e=="number"&&Number.isSafeInteger(e)&&e>=0}function pr(e){return typeof e=="number"&&Number.isSafeInteger(e)&&e>0}var Je=/^[a-f0-9]{64}$/u;function lr(e){return typeof e=="string"&&Je.test(e)}function fr(e){return typeof e=="string"&&e.length>0&&e.length<=256&&!/[\0\r\n]/u.test(e)}function gr(e){return typeof e=="number"&&Number.isFinite(e)&&e>=0}var le=["typescript","javascript","java","scala","kotlin","rust","python","ruby","go","cpp","c","csharp","vb","dart","php","clojure"];var W=2,h=3;var B=new Set(le);function Cr(e){let t=e;if(typeof e=="string")try{t=JSON.parse(e)}catch(s){return{kind:"malformed",reason:`invalid JSON: ${tt(s)}`}}if(!y(t))return{kind:"malformed",reason:"metadata must be a JSON object"};let r=t.version;if(!Number.isInteger(r))return{kind:"malformed",reason:"version must be an integer"};if(r!==W&&r!==h)return{kind:"unsupported",version:r,direction:r<W?"older":"future"};let n=Xe(t,r);if(n)return{kind:"malformed",reason:n};let i=t,o={metadata:i,capabilities:Ye(i)};return r===W?{kind:"legacy",...o,metadata:i}:{kind:"supported",...o,metadata:i}}function Rr(e){return e.kind==="legacy"||e.kind==="supported"?e.metadata:null}function kr(e){if(e.kind!=="legacy"&&e.kind!=="supported"||!e.capabilities.stableGenerationIdentity)return null;let t=e.metadata;return JSON.stringify({version:t.version,status:t.status,updatedAt:t.updatedAt,fingerprint:t.fingerprint,indexedLanguages:t.indexedLanguages,scipCompanion:t.scipCompanion,sqliteLayoutVersion:t.version===h?t.sqliteLayoutVersion:void 0})}function Ye(e){let t=e.fingerprint!==void 0,r=y(e.fingerprint),n=e.indexedLanguages!==void 0,i=e.status==="complete",o=e.version===h?e:null;return{usableForQuery:n,usableForEvidenceCache:t,publishableGeneration:i&&r&&n,stableGenerationIdentity:i&&t&&typeof e.updatedAt=="string",languageShardReuse:!!o?.languageFingerprints,typescriptProjectShardReuse:!!o?.typescriptProjectShards}}function Xe(e,t){if(e.status!=="complete"&&e.status!=="partial")return"status must be complete or partial";if(e.updatedAt!==void 0&&!pe(e.updatedAt))return"updatedAt must be a valid timestamp";for(let r of["requestedLanguages","indexedLanguages"])if(e[r]!==void 0&&!Ke(e[r]))return`${r} must contain unique supported languages`;return e.skipped!==void 0&&!Qe(e.skipped)?"skipped must contain supported language/reason pairs":e.scipCompanion!==void 0&&e.scipCompanion!=="current"&&e.scipCompanion!=="deferred"?"scipCompanion must be current or deferred":t===h&&e.sqliteLayoutVersion!==void 0&&(!Number.isSafeInteger(e.sqliteLayoutVersion)||e.sqliteLayoutVersion<1)?"sqliteLayoutVersion must be a positive safe integer":t===h&&e.languageFingerprints!==void 0&&!Ze(e.languageFingerprints)?"languageFingerprints must map supported languages to fingerprint objects":t===h&&e.typescriptProjectShards!==void 0&&!et(e.typescriptProjectShards)?"typescriptProjectShards must map project names to file fingerprints":null}function Er(e){return e.version===h&&e.sqliteLayoutVersion===1}function Ke(e){return!Array.isArray(e)||!e.every(t=>typeof t=="string"&&B.has(t))?!1:new Set(e).size===e.length}function Qe(e){return Array.isArray(e)&&e.every(t=>y(t)&&typeof t.language=="string"&&B.has(t.language)&&typeof t.reason=="string")}function Ze(e){return y(e)&&Object.entries(e).every(([t,r])=>B.has(t)&&y(r))}function et(e){return y(e)&&Object.values(e).every(t=>y(t)&&Array.isArray(t.files)&&t.files.every(M))}function tt(e){return e instanceof Error?e.message:String(e)}import{closeSync as q,fstatSync as j,openSync as U,readFileSync as rt,readSync as fe}from"fs";import{createHash as nt}from"crypto";var ge=8*1024*1024,it=64*1024*1024,ot=512*1024*1024,st=256*1024*1024,m=class extends Error{constructor(r,n,i,o,s){let a=i==="too-large"?`is ${o} bytes; the safety limit is ${s} bytes`:i==="not-regular"?"is not a regular file":"changed while it was being read";super(`${r} ${JSON.stringify(n)} ${a}`);this.inputKind=r;this.inputPath=n;this.reason=i;this.observedBytes=o;this.limitBytes=s;this.name="BoundedFileReadError"}inputKind;inputPath;reason;observedBytes;limitBytes;code="SCIP_QUERY_BOUNDED_FILE_READ"};function ye(e,t){z(t.maxBytes);let r=String(e),n=U(e,"r");try{let i=j(n);be(i,t,r);let o=rt(n),s=j(n);if(s.dev!==i.dev||s.ino!==i.ino||s.size!==i.size||o.byteLength!==i.size)throw new m(t.inputKind,r,"changed-during-read",s.size,t.maxBytes);return o}finally{q(n)}}function me(e,t,r="utf8"){return ye(e,t).toString(r)}function $(e,t){return me(e,{maxBytes:ge,inputKind:t})}function H(e,t){z(t.maxBytes);let r=[],n=Buffer.allocUnsafe(64*1024),i=0;for(;;){let o=fe(e,n,0,n.length,null);if(o===0)break;if(i+=o,!Number.isSafeInteger(i)||i>t.maxBytes)throw new m(t.inputKind,`file descriptor ${e}`,"too-large",i,t.maxBytes);r.push(Buffer.from(n.subarray(0,o)))}return Buffer.concat(r,i)}function at(e,t,r="utf8"){return H(e,t).toString(r)}function he(e,t){let r=U(e,"r");try{return H(r,t)}finally{q(r)}}function ct(e,t,r="utf8"){return he(e,t).toString(r)}function xe(e,t,r){z(t.maxBytes);let n=String(e),i=U(e,"r");try{let o=j(i);be(o,t,n);let s=Buffer.allocUnsafe(Math.min(1024*1024,Math.max(1,o.size))),a=0;for(;a<o.size;){let c=fe(i,s,0,Math.min(s.length,o.size-a),a);if(c===0)break;r(s.subarray(0,c)),a+=c}let u=j(i);if(u.dev!==o.dev||u.ino!==o.ino||u.size!==o.size||a!==o.size)throw new m(t.inputKind,n,"changed-during-read",u.size,t.maxBytes);return a}finally{q(i)}}function ut(e,t){let r=nt("sha256");return xe(e,t,n=>r.update(n)),r.digest("hex")}function be(e,t,r){if(!e.isFile())throw new m(t.inputKind,r,"not-regular",Number(e.size),t.maxBytes);if(e.size>t.maxBytes)throw new m(t.inputKind,r,"too-large",Number(e.size),t.maxBytes)}function z(e){if(!Number.isSafeInteger(e)||e<0)throw new RangeError(`maxBytes must be a non-negative safe integer; received ${e}`)}import{spawnSync as pt}from"child_process";import{createHash as lt}from"crypto";import{existsSync as ft,lstatSync as gt,realpathSync as yt}from"fs";import{dirname as mt,isAbsolute as ht,join as xt,relative as qr,resolve as I,sep as Ur}from"path";var Se=Symbol.for("scip-query.project-file-listing-context.v1"),Ce=globalThis,V=Ce[Se],x=V&&typeof V=="object"?V:{};Ce[Se]=x;function Or(e,t){let r=x.active?x.canonicalProjectRoots:void 0,n=r?.get(e);if(n!==void 0)return n;let i=t();return r?.set(e,i),i}function Re(){return x.sequence??0}function _r(e,t,r){let n=x.active,i=n?.get(e);if(i&&i.pathBytes<=t)return i;let o=dt(r(),(x.sequence??0)+1);if(x.sequence=o.sequence,o.pathBytes>t)throw new RangeError(`Git project file listing exceeded ${t} path bytes.`);return n?.set(e,o),o}function*Lr(e){let t=0;for(;t<e.taggedOutput.length;){let r=e.taggedOutput.indexOf("\0",t);if(r<0)return;yield e.taggedOutput.slice(t+2,r),t=r+1}}function dt(e,t){let r=0,n=0,i=!0;for(;r<e.length;){let o=e.indexOf("\0",r);if(o<0||o<=r+2||e[r+1]!==" ")throw new Error("Git returned a malformed tagged project file listing.");let s=e[r];i&&=s==="H"||s==="?",n+=1,r=o+1}return{taggedOutput:e,pathBytes:Buffer.byteLength(e,"utf8")-n*2,indexAllowsTreeFingerprintReuse:i,sequence:t}}var C={run(e,t){let r=Ee(e,t);return r.kind==="success"?r.output:void 0},runResult:Ee},bt=["rev-parse","--show-toplevel","--absolute-git-dir","--git-common-dir","HEAD","HEAD^{tree}"],Pe=["status","--porcelain=v2","--branch","-z","--untracked-files=all"],w=/^[0-9a-f]{40,64}$/;function Hr(e,t,r=C){if(!t||t.startsWith("-")||/[\0\r\n]/.test(t))throw new Error(`Invalid Git revision ${JSON.stringify(t)}.`);let n=r.runResult(e,["rev-parse","--verify","--end-of-options",`${t}^{commit}`]);if(n.kind!=="success"||!w.test(n.output))throw new Error(`Git revision ${JSON.stringify(t)} does not resolve to exactly one commit.`);return n.output}function zr(e,t=C){return St(e,t)?.context}function St(e,t=C){let r=t.runResult(e,bt);if(r.kind==="success"){let i=Ct(r.output);if(i){let o=Rt(i,t);if(o)return ke(o)}}let n=kt(e,t);return n?ke(n):void 0}function ke(e){return{context:e,projectFileInventorySequence:Re()}}function je(e){let t=e.split("\0").filter(Boolean),r=t.find(i=>i.startsWith("# branch.oid "))?.slice(13),n=r==="(initial)"?void 0:r;if(!(n!==void 0&&!w.test(n))&&r!==void 0)return{headCommit:n,clean:t.every(i=>i.startsWith("# "))}}function Ct(e){let t=e.split(`
|
|
2
|
+
`).map(u=>u.trim());if(t.length!==5)return;let[r,n,i,o,s]=t;if(!r||!n||!i||!o||!s||!w.test(o)||!w.test(s))return;let a=b(r);return{root:a,gitDir:b(v(a,n)),commonDir:b(v(a,i)),headCommit:o,treeOid:s}}function Rt(e,t){let r=t.run(e.root,Pe);if(r===void 0)return;let n=je(r);return n?.headCommit!==e.headCommit?void 0:{...we(e.root,e.gitDir),commonDir:e.commonDir,repositoryId:Y("repository",e.commonDir),headCommit:e.headCommit,treeOid:e.treeOid,clean:n.clean}}function kt(e,t){let r=Et(e,t);if(r.kind!=="worktree")return;let n=r.identity,i=n.projectRoot,o=t.run(i,["rev-parse","--git-common-dir"])?.trim();if(!o)return;let s=b(v(i,o)),a=J(t.run(i,["rev-parse","--verify","HEAD"])),u=J(t.run(i,["rev-parse","--verify","HEAD^{tree}"])),c=t.run(i,Pe);if(c===void 0)return;let l=je(c);if(!(!l||l.headCommit!==a))return{...n,commonDir:s,repositoryId:Y("repository",s),headCommit:a,treeOid:u,clean:l.clean}}function Et(e,t=C){let r=t.runResult(e,["rev-parse","--show-toplevel"]);if(r.kind==="not-repository")return{kind:"non-git"};if(r.kind==="error")return r;let n=r.output.trim();if(!n)return{kind:"error",message:"Git returned an empty worktree root."};let i=b(n),o=t.run(i,["rev-parse","--absolute-git-dir"])?.trim();if(!o)return{kind:"error",message:"Git did not return an absolute worktree directory."};let s=b(v(i,o));return{kind:"worktree",identity:we(i,s)}}function we(e,t){return{projectRoot:e,gitDir:t,worktreeId:Y("worktree",`${e}\0${t}`)}}function Vr(e,t,r=C){return J(r.run(e,t))}function v(e,t){return ht(t)?t:I(e,t)}function b(e){try{return yt(e)}catch{return I(e)}}function Y(e,t){return lt("sha256").update(`${e}\0${t}`).digest("hex").slice(0,24)}function J(e){return e?.trim()||void 0}function Ee(e,t){let r=pt("git",["-C",e,...t],{encoding:"utf-8",env:{...process.env,LC_ALL:"C"},maxBuffer:52428800,stdio:["ignore","pipe","pipe"],timeout:3e4,killSignal:"SIGKILL"});if(r.status===0)return{kind:"success",output:r.stdout.trimEnd()};let i=(typeof r.stderr=="string"?r.stderr.trim():"")||r.error?.message||`git exited with status ${r.status??"unknown"}`,o=r.error?.code;return(/not a git repository/i.test(i)||o==="ENOENT"&&ft(I(e)))&&!Pt(e)?{kind:"not-repository"}:{kind:"error",message:i}}function Pt(e){if(process.env.GIT_DIR||process.env.GIT_COMMON_DIR)return!0;let t=I(e);for(;;){try{return gt(xt(t,".git")),!0}catch(n){let i=n.code;if(i!=="ENOENT"&&i!=="ENOTDIR")return!0}let r=mt(t);if(r===t)return!1;t=r}}import{createHash as _e,randomUUID as _t}from"crypto";import{chmodSync as Le,existsSync as S,linkSync as Lt,lstatSync as O,readdirSync as Q,realpathSync as p,unlinkSync as Tt,writeSync as Gt}from"fs";import{homedir as Mt}from"os";import{basename as Nt,dirname as _,isAbsolute as Ae,join as d,resolve as L}from"path";import{closeSync as jt,existsSync as wt,fsyncSync as vt,mkdirSync as It,openSync as Ft}from"fs";import{dirname as Ie}from"path";function ve(e,t,r,n){let i=0;for(;i<t.length;){let o=r.writeFile(e,t,i,t.length-i);if(!Number.isSafeInteger(o)||o<=0||o>t.length-i)throw new Error(`${n} write did not make valid forward progress`);i+=o}}function X(e,t){if(t!=="win32")return!1;let r=e.code;return r==="EACCES"||r==="EBADF"||r==="EINVAL"||r==="EISDIR"||r==="EPERM"}var R=Object.freeze({platform:process.platform,pathExists:e=>wt(e),makeDirectory:e=>It(e,{recursive:!0}),openFile:(e,t,r)=>Ft(e,t,r),syncFile:e=>vt(e),closeFile:e=>jt(e)});function Fe(e,t=R){let r=[],n=e;for(;!t.pathExists(n);){r.push(n);let o=Ie(n);if(o===n)throw new Error(`Cannot establish a durable directory path without an existing ancestor: ${e}`);n=o}let i="synced";for(let o of r.reverse())t.makeDirectory(o),i=D(i,F(Ie(o),t));return i}function F(e,t=R){let r;try{r=t.openFile(e,"r")}catch(n){if(X(n,t.platform))return"unsupported";throw n}try{t.syncFile(r)}catch(n){try{t.closeFile(r)}catch{}if(X(n,t.platform))return"unsupported";throw n}return t.closeFile(r),"synced"}function D(...e){return e.every(t=>t==="not-requested")?"not-requested":e.includes("unsupported")?"unsupported":"synced"}import{createRequire as Dt}from"module";var At=Dt(import.meta.url),De=Ot().version;function Ot(){for(let e of["../package.json","../../package.json"])try{return At(e)}catch{}return{version:"0.0.0"}}var Te=1,E=".scip-query-cache-owner.json",Wt=16*1024,Ge=Object.freeze({...R,randomToken:()=>_t(),linkFile:(e,t)=>Lt(e,t),removeFile:e=>Tt(e),writeFile:(e,t,r,n)=>Gt(e,t,r,n)});function A(e,t){return Object.assign(new Error(`refusing unsafe project dbPath ${JSON.stringify(e)} (${t}); use a repository-relative directory that remains inside the checkout`),{name:"UnsafeCachePathError",code:"SCIP_QUERY_UNSAFE_CACHE_PATH",configuredPath:e,reason:t})}function f(e,t){return Object.assign(new Error(`refusing unowned cache directory ${JSON.stringify(e)} (${t}); move unrelated data elsewhere or choose a new empty dbPath`),{name:"CacheOwnershipError",code:"SCIP_QUERY_CACHE_OWNERSHIP",cacheDir:e,reason:t})}function Bt(e,t){let r=p(e);return $t(r,qt(r,t))}function qt(e,t){let r=p(e),n=process.env.SCIP_QUERY_CACHE_DIR;return n?L(n):t?.dbPath?zt(r,t.dbPath):Ut(r)}function Me(){let e=process.env.XDG_CACHE_HOME;return d(e||d(Mt(),".cache"),"scip-query")}function Ut(e){let t=L(e);try{t=p(t)}catch{}let r=_e("sha256").update(t).digest("hex").slice(0,12);return d(Me(),"projects",r)}function ln(e){if(!/^[a-f0-9]{24}$/.test(e))throw new Error(`invalid repository cache identity: ${e}`);let t=d(Me(),"repositories",e);return Be(t),p(t)}function fn(e){return process.env.SCIP_QUERY_SHARED_CACHE!=="0"&&!process.env.SCIP_QUERY_CACHE_DIR&&!process.env.SCIP_QUERY_INDEX_DB&&!e?.dbPath}function gn(e,t){let r=Bt(e,t);return{cacheDir:r,dbPath:d(r,"index.db"),indexPath:d(r,"index.scip"),metaPath:d(r,"meta.json")}}function $t(e,t,r=Ge){return Ht(e,t,r).cacheDir}function Ht(e,t,r=Ge){let n=p(e),i=S(t)?"synced":Be(t,r),o=p(t),s=d(o,E);if(S(s))return K(n,o),Z(s),k(o),{kind:"existing",cacheDir:o};Oe(o),Kt(o),Oe(o);let u=`${JSON.stringify({schemaVersion:Te,canonicalProjectRoot:n,canonicalCacheDir:o,creatorVersion:De},null,2)}
|
|
3
|
+
`;try{let c=Qt(s,u,r),l=D(i,c);return{kind:"published",cacheDir:o,achievedDurability:l==="synced"?"directory-durable":"file-flushed",directorySync:l}}catch(c){if(er(c))return K(n,o),{kind:"existing",cacheDir:o};throw c}}function K(e,t){let r=p(e),n=p(t);return Jt(n,r,n)}function yn(e,t){return S(d(t,E))?(K(e,t),Ne(t),!0):!1}function zt(e,t){let r;try{r=te(t)}catch(s){throw s instanceof g?A(t,s.reason):s}let n=L(e,...r.split("/"));if(n===e||!G(e,n))throw A(t,"outside-project");let i=Vt(n),o=p(i);if(!G(e,o)&&o!==e)throw A(t,"symlink-escape");return n}function Vt(e){let t=e;for(;!S(t);){let r=_(t);if(r===t)throw A(e,"no-existing-ancestor");t=r}return t}function Jt(e,t,r){let n=d(e,E);if(!S(n)||O(n).isSymbolicLink())throw f(e,"missing regular ownership record");let i=O(n);if(!i.isFile()||i.size>Wt)throw f(e,"invalid ownership record file");let o=$(n,"cache ownership record"),s=Yt(o,e);if(t!==void 0&&s.canonicalProjectRoot!==t)throw f(e,"ownership record belongs to a different project");if(s.canonicalCacheDir!==r)throw f(e,"ownership record names a different cache directory");return{record:s,ownerSha256:_e("sha256").update(o).digest("hex"),physicalCacheDir:e}}function Yt(e,t){try{let r=JSON.parse(e);if(r.schemaVersion!==Te||typeof r.canonicalProjectRoot!="string"||typeof r.canonicalCacheDir!="string"||typeof r.creatorVersion!="string"||!Ae(r.canonicalProjectRoot)||!Ae(r.canonicalCacheDir))throw new Error("invalid fields");return r}catch(r){throw f(t,`malformed ownership record: ${r instanceof Error?r.message:String(r)}`)}}function Oe(e){let t=Q(e).filter(r=>r!==E&&!Xt(r));if(t.length>0)throw f(e,`unrecognized existing entries: ${t.slice(0,3).join(", ")}`)}function Xt(e){return e.startsWith(`${E}.tmp-`)||e.startsWith("git-worktree-context.json.tmp-")||[".scipquery-generations","affected-shadow-latest.json","affected-shadow.jsonl","agent-hooks","augment-vue-meta.json","cache-lifecycle.lock","evidence.db","evidence.db-shm","evidence.db-wal","health-report-cache.json","git-worktree-context.json","index.db","index.db-shm","index.db-wal","index.lock","index.scip","language-indexes","meta.json","reindex-activity.jsonl","shared-cache.json","typescript-index","typescript-scip-fragments","typescript-scip-overlays","typescript-semantic","watch-activity.json","watch-refresh-requests","watch-state.json","watch.lock"].includes(e)?!0:/^(?:reindex-|rust-|typescript-)/.test(e)}function Kt(e){for(let t of Q(e)){let r=d(e,t);try{let n=O(r);if(n.isSymbolicLink())throw f(e,`legacy cache entry ${t} is a symlink`);if(n.isDirectory())k(r);else if(n.isFile())Z(r);else throw f(e,`legacy cache entry ${t} is not a file or directory`)}catch(n){if(We(n))continue;throw n}}k(e)}function Ne(e,t=!1){try{let r=O(e);if(r.isSymbolicLink())throw f(e,"managed cache tree contains a symlink");if(r.isFile()){Z(e);return}if(!r.isDirectory())throw f(e,"managed cache tree contains a special file");k(e);for(let n of Q(e))Ne(d(e,n),!0)}catch(r){if(t&&We(r))return;throw r}}function We(e){let t=e?.code;return t==="ENOENT"||t==="ENOTDIR"}function Be(e,t=R){let r=Fe(e,t);return k(e),r}function Qt(e,t,r){let n=`${e}.tmp-${process.pid}-${r.randomToken()}`,i,o=!1;try{i=r.openFile(n,"wx",384),o=!0,ve(i,Buffer.from(t),r,"cache ownership record"),r.syncFile(i),r.closeFile(i),i=void 0,r.linkFile(n,e);let s=F(_(e),r);return r.removeFile(n),o=!1,D(s,F(_(e),r))}finally{if(i!==void 0)try{r.closeFile(i)}catch{}if(o)try{r.removeFile(n)}catch{}}}function k(e){process.platform!=="win32"&&Le(e,448)}function Z(e){process.platform!=="win32"&&Le(e,384)}function Zt(e){if(S(e))return p(e);let t=p(_(e));return d(t,Nt(e))}function mn(e){return Zt(L(e))}function er(e){return typeof e=="object"&&e!==null&&"code"in e&&e.code==="EEXIST"}export{g as a,T as b,rr as c,nr as d,G as e,te as f,Ue as g,or as h,sr as i,ar as j,ze as k,y as l,pe as m,ur as n,dr as o,pr as p,lr as q,fr as r,gr as s,le as t,h as u,Cr as v,Rr as w,kr as x,Ye as y,Er as z,ge as A,it as B,ot as C,st as D,m as E,ye as F,me as G,$ as H,at as I,ct as J,xe as K,ut as L,z as M,ve as N,X as O,R as P,Fe as Q,F as R,D as S,Or as T,_r as U,Lr as V,C as W,Hr as X,zr as Y,Vr as Z,v as _,b as $,De as aa,qt as ba,Me as ca,Ut as da,ln as ea,fn as fa,gn as ga,yn as ha,mn as ia};
|
|
4
|
+
//# sourceMappingURL=chunk-MO226P4Q.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as i}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as i}from"./chunk-IDPLC3FI.js";function l(n,o,s,t={}){let e=i(n,o,s,t);return e?{symbolA:e.symbolA,symbolB:e.symbolB,similarity:e.similarity,sharedCallees:e.sharedEvidence,uniqueToA:e.uniqueToA,uniqueToB:e.uniqueToB,consolidationStrategy:e.consolidationStrategy}:null}export{l as a};
|
|
2
|
+
//# sourceMappingURL=chunk-MOBF2GH6.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
var x=new Map([[8,"\u2408"],[9,"\u2409"],[10,"\u2424"],[13,"\u240D"]]);function c(n,e={}){let o=e.allowNewlines??!0,r=e.allowTabs??!0,l="";for(let i=0;i<n.length;){let t=n.charCodeAt(i);if(t===27){i=a(n,i);continue}if(t===155){i=s(n,i+1);continue}if(t===144||t===152||t===157||t===158||t===159){i=u(n,i+1);continue}if(w(t)){t===10&&o?l+=`
|
|
2
|
+
`:t===9&&r?l+=" ":l+=x.get(t)??"\uFFFD",i+=1;continue}if(b(t)){l+="\uFFFD",i+=1;continue}l+=n[i],i+=1}return l}function C(n){return c(n,{allowNewlines:!1,allowTabs:!1})}function a(n,e){let o=n.charCodeAt(e+1);if(Number.isNaN(o))return n.length;if(o===91)return s(n,e+2);if(o===80||o===88||o===93||o===94||o===95)return u(n,e+2);let r=e+1;for(;r<n.length&&f(n.charCodeAt(r));)r+=1;return r<n.length&&T(n.charCodeAt(r))?r+1:e+1}function s(n,e){let o=e;for(;o<n.length;){let r=n.charCodeAt(o);if(o+=1,r>=64&&r<=126)return o}return n.length}function u(n,e){let o=e;for(;o<n.length;){let r=n.charCodeAt(o);if(r===7||r===156)return o+1;if(r===27&&n.charCodeAt(o+1)===92)return o+2;o+=1}return n.length}function f(n){return n>=32&&n<=47}function T(n){return n>=48&&n<=126}function w(n){return n<=31||n>=127&&n<=159}function b(n){return n===1564||n===8206||n===8207||n>=8234&&n<=8238||n>=8294&&n<=8297}export{C as a};
|
|
3
|
+
//# sourceMappingURL=chunk-MXNGIEPU.js.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import{H as y,J as W,L as Q,N as F,O as v,P as K,Q as g,R as b,S as P,v as U,x as z}from"./chunk-MO226P4Q.js";var Ee=new Set(["aix","android","darwin","freebsd","haiku","linux","openbsd","sunos","win32","cygwin","netbsd"]);function L(t){if(!t||typeof t!="object"||Array.isArray(t))return null;let e=t;return e.version!==1||typeof e.pid!="number"||!Number.isSafeInteger(e.pid)||e.pid<=0||typeof e.platform!="string"||!Ee.has(e.platform)||typeof e.startToken!="string"||e.startToken.trim()===""?null:{version:1,pid:e.pid,platform:e.platform,startToken:e.startToken}}function p(t,e){return t.version===e.version&&t.pid===e.pid&&t.platform===e.platform&&t.startToken===e.startToken}import{execFileSync as Te}from"child_process";import{platform as ve}from"os";var De=1e3,Y=16*1024,D;function S(t,e=V){if(!Number.isSafeInteger(t)||t<=0)return null;let r=t===process.pid&&e===V;if(r&&D)return{...D};try{let n=Ae(t,e);if(!n)return null;let i={version:1,pid:t,platform:e.platform,startToken:n};return r&&(D=i),{...i}}catch{return null}}function Ae(t,e){if(e.platform==="linux"||e.platform==="android")return Oe(e.readFile(`/proc/${t}/stat`));if(e.platform==="win32"){let r=`([DateTimeOffset](Get-Process -Id ${t} -ErrorAction Stop).StartTime).ToUnixTimeMilliseconds()`;return H(e.run("powershell.exe",["-NoProfile","-NonInteractive","-Command",r]))}return e.platform==="darwin"||e.platform==="freebsd"||e.platform==="openbsd"||e.platform==="netbsd"?H(e.run("ps",["-p",String(t),"-o","lstart="])):null}function Oe(t){let e=t.lastIndexOf(")");if(e<0)return null;let n=t.slice(e+1).trim().split(/\s+/)[19];return n&&/^\d+$/.test(n)?n:null}function H(t){let e=t.trim();return e===""?null:e}var V={platform:ve(),readFile(t){return W(t,{maxBytes:Y,inputKind:"process identity pseudo-file"})},run(t,e){return Te(t,[...e],{encoding:"utf8",timeout:De,maxBuffer:Y,env:{...process.env,LC_ALL:"C",LANG:"C"},stdio:["ignore","pipe","ignore"]})}};function x(t){try{return process.kill(t,0),!0}catch(e){return typeof e=="object"&&e!==null&&"code"in e&&e.code==="EPERM"}}function X(){return performance.now()}function Me(t,e){return t.reason instanceof Error?t.reason:new Error(e)}function nr(t,e){if(t?.aborted)throw Me(t,e)}import{randomUUID as Ne}from"crypto";import{closeSync as Ge,fsyncSync as _e,linkSync as qe,mkdirSync as Ce,openSync as Be,statSync as $e,unlinkSync as je,writeSync as Je}from"fs";import{dirname as G}from"path";var O="scip-query-process-lock",M=1,E=Object.freeze({wallNow:()=>Date.now(),isProcessAlive:x,readProcessIdentity:S,randomToken:()=>Ne(),makeDirectory:t=>Ce(t,{recursive:!0}),openFile:(t,e,r)=>Be(t,e,r),writeFile:(t,e,r,n)=>Je(t,e,r,n),syncFile:t=>_e(t),closeFile:t=>Ge(t),linkFile:(t,e)=>qe(t,e),readFile:t=>y(t,"process lock record"),statFile:t=>{let e=$e(t);return{dev:e.dev,ino:e.ino,size:e.size,mtimeMs:e.mtimeMs}},removeFile:t=>je(t)});function Z(t,e){let r=e.runtime??E;r.makeDirectory(G(t));let n;for(let i=0;i<2;i+=1)try{return{kind:"acquired",lock:ee(t,e,r),...n?{reclaimed:n}:{}}}catch(o){if(o.code!=="EEXIST")throw o;let s=k(t,{parseLegacy:e.parseLegacy,runtime:r});if(i===0&&ze(t,s,{creationGraceMs:e.creationGraceMs,parseLegacy:e.parseLegacy,runtime:r})){n=s;continue}return{kind:"contended",observation:s}}return{kind:"contended",observation:k(t,{parseLegacy:e.parseLegacy,runtime:r})}}function k(t,e={}){let r=e.runtime??E,n,i;try{n=r.statFile(t),i=r.readFile(t)}catch(l){return l.code==="ENOENT"?{state:"missing"}:{state:"malformed"}}let o;try{o=JSON.parse(i)}catch{return{state:"malformed",raw:i,identity:n}}let s=Ue(o);if(s)return{state:"valid",raw:i,identity:n,record:s,owner:Ke(s),parsed:o};let a=e.parseLegacy?.(o)??null;return a?{state:"legacy",raw:i,identity:n,owner:a,parsed:o}:{state:"malformed",raw:i,identity:n,parsed:o}}function Ue(t){if(!t||typeof t!="object"||Array.isArray(t))return null;let e=t;if(e.protocol!==O||e.version!==M||typeof e.kind!="string"||e.kind.trim()===""||typeof e.pid!="number"||!Number.isSafeInteger(e.pid)||e.pid<=0||typeof e.token!="string"||e.token.trim()===""||typeof e.startedAt!="string"||!Number.isFinite(Date.parse(e.startedAt))||e.detail!==void 0&&(typeof e.detail!="object"||e.detail===null||Array.isArray(e.detail)))return null;let r=e.processIdentity===void 0?null:L(e.processIdentity);return e.processIdentity!==void 0&&(!r||r.pid!==e.pid)?null:{protocol:O,version:M,kind:e.kind,pid:e.pid,token:e.token,...r?{processIdentity:r}:{},startedAt:e.startedAt,...e.detail?{detail:e.detail}:{}}}function ze(t,e,r={}){let n=r.runtime??E;if(!N(e,n))return!1;let i=Qe(`${t}.reclaim`,n);if(!i)return!1;try{let o=k(t,{parseLegacy:r.parseLegacy,runtime:n});return!re(e,o)||!N(o,n)?!1:_(t,n)}finally{i.release()}}function ee(t,e,r){let n=e.directoryDurability??"durable",i=e.pid??process.pid,o=r.randomToken(),s=e.processIdentity===void 0?r.readProcessIdentity(i):e.processIdentity,a={protocol:O,version:M,kind:e.kind,pid:i,token:o,...s?{processIdentity:s}:{},startedAt:new Date(r.wallNow()).toISOString(),...e.detail?{detail:e.detail}:{}},l=`${t}.${o}.candidate`,c=r.openFile(l,"wx",384),d;try{F(c,Buffer.from(`${JSON.stringify(a)}
|
|
2
|
+
`),r,"process lock"),r.syncFile(c)}catch(m){d=m}try{r.closeFile(c)}catch(m){d??=m}if(d!==void 0)throw A(l,r),d;try{r.linkFile(l,t)}catch(m){throw A(l,r),m}if(A(l,r),n==="durable")try{ne(G(t),r)}catch(m){throw We(t,a,r),m}let f=!1;return{path:t,record:a,release:()=>f?!1:(f=!0,te(t,a,r,n))}}function We(t,e,r=E){return te(t,e,r,"durable")}function te(t,e,r,n){let i=k(t,{runtime:r});return i.state!=="valid"||!i.record||i.record.pid!==e.pid||i.record.token!==e.token||e.processIdentity&&(!i.record.processIdentity||!p(e.processIdentity,i.record.processIdentity))?!1:_(t,r,n)}function Qe(t,e){for(let r=0;r<2;r+=1)try{return ee(t,{kind:"reclaim-guard",runtime:e},e)}catch(n){if(n.code!=="EEXIST")return null;let i=k(t,{runtime:e});if(r>0||!N(i,e))return null;let o=k(t,{runtime:e});if(!re(i,o)||!_(t,e))return null}return null}function N(t,e){if(t.state==="missing")return!1;if(t.owner){if(!e.isProcessAlive(t.owner.pid))return!0;if(!t.owner.processIdentity)return!1;let r=e.readProcessIdentity(t.owner.pid);return r!==null&&!p(t.owner.processIdentity,r)}return!1}function re(t,e){return t.state===e.state&&t.raw===e.raw&&t.identity!==void 0&&e.identity!==void 0&&t.identity.dev===e.identity.dev&&t.identity.ino===e.identity.ino&&t.identity.size===e.identity.size&&t.identity.mtimeMs===e.identity.mtimeMs}function Ke(t){return{pid:t.pid,...t.processIdentity?{processIdentity:t.processIdentity}:{}}}function ne(t,e){let r;try{r=e.openFile(t,"r")}catch(n){if(v(n,process.platform))return;throw n}try{e.syncFile(r)}catch(n){if(!v(n,process.platform))throw n}finally{e.closeFile(r)}}function _(t,e,r="durable"){try{return e.removeFile(t),r==="durable"&&ne(G(t),e),!0}catch{return!1}}function A(t,e){try{e.removeFile(t)}catch{}}import{join as Ye}from"path";var He=t=>{if(!t||typeof t!="object"||Array.isArray(t))return null;let e=t.pid;return typeof e=="number"&&Number.isSafeInteger(e)&&e>0?{pid:e}:null};function br(t,e={}){return q(Ye(t,"gc.lock"),e)}function q(t,e={}){let r=e.waitMs??0,n=e.pollMs??10,i=e.now??X,o=i()+r;do{let s=Ve(t,e.directoryDurability);if(s)return Xe(s);let a=o-i();if(a<=0)return null;Ze(Math.min(n,a))}while(i()<=o);return null}function Ve(t,e){let r=Z(t,{kind:"generic",parseLegacy:He,...e?{directoryDurability:e}:{}});return r.kind==="acquired"?r.lock:null}function Xe(t){return{release:()=>{t.release()}}}function Ze(t){let e=new Int32Array(new SharedArrayBuffer(Int32Array.BYTES_PER_ELEMENT));Atomics.wait(e,0,0,t)}import{randomUUID as ot}from"crypto";import{closeSync as st,existsSync as at,fsyncSync as ct,linkSync as lt,mkdirSync as dt,openSync as ut,renameSync as ft,unlinkSync as mt,writeSync as pt}from"fs";import{dirname as oe}from"path";import{chmodSync as et,constants as tt,copyFileSync as rt}from"fs";import{dirname as nt}from"path";var ie=Object.freeze({...K,copyFile:(t,e)=>rt(t,e,tt.COPYFILE_FICLONE),chmodFile:(t,e)=>et(t,e)});function it(t,e,r={}){let n=r.runtime??ie,i=nt(e),o=g(i,n);n.copyFile(t,e),r.mode!==void 0&&n.chmodFile(e,r.mode);let s=n.openFile(e,"r");try{n.syncFile(s)}finally{n.closeFile(s)}return P(o,b(i,n))}var se=Object.freeze({platform:process.platform,randomToken:()=>ot(),pathExists:t=>at(t),makeDirectory:t=>dt(t,{recursive:!0}),openFile:(t,e,r)=>ut(t,e,r),writeFile:(t,e,r,n)=>pt(t,e,r,n),syncFile:t=>ct(t),closeFile:t=>st(t),renameFile:(t,e)=>ft(t,e),linkFile:(t,e)=>lt(t,e),removeFile:t=>mt(t)});function C(t,e,r={}){let n=r.durability??"visibility",i=r.runtime??se,o=oe(t),s=n==="durable"?g(o,i):(i.makeDirectory(o),"not-requested"),a=`${t}.tmp-${i.randomToken()}`,l=typeof e=="string"?Buffer.from(e):e,c,d=!1;try{c=i.openFile(a,"wx",r.mode??384),d=!0,F(c,l,i,"atomic file"),n==="durable"&&i.syncFile(c),i.closeFile(c),c=void 0,i.renameFile(a,t),d=!1;let f=n==="durable"?P(s,b(o,i)):"not-requested";return ae(n,f)}finally{if(c!==void 0)try{i.closeFile(c)}catch{}if(d)try{i.removeFile(a)}catch{}}}function xr(t,e,r={}){let n=r.durability??"visibility",i=r.runtime??se;if(!i.linkFile)throw new Error("Exclusive atomic file publication requires hard-link support.");let o=oe(t),s=n==="durable"?g(o,i):(i.makeDirectory(o),"not-requested"),a=`${t}.tmp-${i.randomToken()}`,l=typeof e=="string"?Buffer.from(e):e,c,d=!1;try{c=i.openFile(a,"wx",r.mode??384),d=!0,F(c,l,i,"exclusive atomic file"),n==="durable"&&i.syncFile(c),i.closeFile(c),c=void 0,i.linkFile(a,t);let f=n==="durable"?b(o,i):"not-requested";i.removeFile(a),d=!1;let m=n==="durable"?P(s,f,b(o,i)):"not-requested";return ae(n,m)}finally{if(c!==void 0)try{i.closeFile(c)}catch{}if(d)try{i.removeFile(a)}catch{}}}function ae(t,e){return{requestedDurability:t,achievedDurability:t==="visibility"?"visibility":e==="synced"?"directory-durable":"file-flushed",directorySync:e}}function ce(t,e,r={}){C(t,le(e,r),{durability:"visibility",runtime:r.runtime})}function Ar(t,e,r={}){return C(t,le(e,r),{durability:"durable",runtime:r.runtime})}function le(t,e){let r=JSON.stringify(t,null,e.spacing);return e.trailingNewline?`${r}
|
|
3
|
+
`:r}import{createHash as yt,randomUUID as bt}from"crypto";import{existsSync as w,mkdirSync as gt,readdirSync as Pt,rmSync as ue,statSync as fe}from"fs";import{basename as St,dirname as T,join as u}from"path";var kt=1,wt=1,It=".scipquery-generations",Ft="manifest.json",me="readers",Lt="gc.lock",Rt=128,R=new Map,pe={pid:process.pid,now:()=>new Date,randomToken:()=>bt(),isProcessAlive:x,readProcessIdentity:S};function I(t){return u(T(t),It)}function ht(t){return u(I(t),Lt)}function Ur(t,e=pe){let r=q(ht(t.dbPath),{waitMs:5e3,directoryDurability:"recoverable"});if(!r)throw new Error("SQLite generation retention is busy; retry opening the index.");let n;try{let i=Dt(t);if(i.source!=="immutable")return{generation:i,release(){}};let o=e.randomToken();if(!/^[A-Za-z0-9._-]+$/.test(o))throw new Error("SQLite generation reader token is unsafe.");let s=u(I(t.dbPath),me);gt(s,{recursive:!0}),n=u(s,`${e.pid}-${o}.json`);let a=e.readProcessIdentity(e.pid);ce(n,{version:1,token:o,generationIdentity:i.identity,pid:e.pid,...a?{processIdentity:a}:{},acquiredAt:e.now().toISOString()},{spacing:2,trailingNewline:!0});let l=!1;return{generation:i,release(){l||!n||(l=!0,ue(n,{force:!0}))}}}finally{r.release()}}function zr(t,e,r=pe,n={}){let i=u(I(t),me);if(!w(i))return{protectedGenerations:new Set,activeLeases:0,staleLeasesRemoved:0,malformedLeases:0};let o=new Set,s=0,a=0,l=0;for(let c of Pt(i,{withFileTypes:!0})){if(!c.isFile()||!c.name.endsWith(".json"))continue;let d=u(i,c.name),f;try{f=xt(JSON.parse(y(d,"SQLite generation reader lease")))}catch{f=null}if(!f){l+=1;for(let m of e)o.add(m);continue}if(!Et(f,r)){n.removeStale!==!1&&(ue(d,{force:!0}),a+=1);continue}s+=1,o.add(f.generationIdentity)}return{protectedGenerations:o,activeLeases:s,staleLeasesRemoved:a,malformedLeases:l}}function xt(t){if(!t||typeof t!="object"||Array.isArray(t))return null;let e=t,r=e.processIdentity===void 0?null:L(e.processIdentity);return e.version!==1||typeof e.token!="string"||e.token.trim()===""||typeof e.generationIdentity!="string"||!/^[a-f0-9]{64}$/.test(e.generationIdentity)||typeof e.pid!="number"||!Number.isSafeInteger(e.pid)||e.pid<=0||typeof e.acquiredAt!="string"||!Number.isFinite(Date.parse(e.acquiredAt))||e.processIdentity!==void 0&&(!r||r.pid!==e.pid)?null:{version:1,token:e.token,generationIdentity:e.generationIdentity,pid:e.pid,...r?{processIdentity:r}:{},acquiredAt:e.acquiredAt}}function Et(t,e){if(!e.isProcessAlive(t.pid))return!1;if(!t.processIdentity)return!0;let r=e.readProcessIdentity(t.pid);return r===null||p(t.processIdentity,r)}function ye(t){try{let e=JSON.parse(y(u(I(t),"state.json"),"SQLite generation state"));return Gt(e)?e:null}catch{return null}}function Tt(t,e){return vt(I(t),e)}function vt(t,e){try{let r=JSON.parse(y(u(t,e,Ft),"SQLite generation manifest"));return Nt(r,e)?r:null}catch{return null}}function Dt(t){let e=ye(t.dbPath);if(e){let r=Ot(t,e.currentGeneration);if(r)return r;if(e.artifactSet==="immutable-v1")throw new Error(`Published SQLite generation ${e.currentGeneration} is missing or invalid.`)}if(w(u(T(t.dbPath),"index.lock")))throw new Error("Legacy SQLite publication is in progress; retry after the reindex lock is released.");return Mt(t,e?.currentGeneration)}function Wr(t){let e=ye(t);if(e)return e.currentGeneration;try{let r=u(T(t),"meta.json"),n=w(r)?y(r,"reindex metadata"):void 0;return be(t,n)}catch{return null}}function At(t){return z(U(t))??t}function Ot(t,e){try{let r=u(I(t.dbPath),e),n=Tt(t.dbPath,e);if(!n)return null;let i=B(r,n.database),o=n.index?B(r,n.index):void 0,s=n.metadata?B(r,n.metadata):void 0;return!$(i,n.database)||n.index&&(!o||!$(o,n.index))||n.metadata&&(!s||!$(s,n.metadata))?null:{identity:e,databasePath:i,...o?{indexPath:o}:{},...s?{metadataPath:s,metadataRaw:y(s,"reindex metadata")}:{},source:"immutable"}}catch{return null}}function Mt(t,e){let r=ge(t.dbPath),n=u(T(t.dbPath),"meta.json"),i=w(n)?y(n,"reindex metadata"):void 0,o=w(t.indexPath)?t.indexPath:void 0;return{identity:e??be(t.dbPath,i),databasePath:t.dbPath,...o?{indexPath:o}:{},...i===void 0?{}:{metadataPath:n,metadataRaw:i},source:"legacy",databaseFileIdentity:r}}function be(t,e){let r=yt("sha256").update("sqlite-generation-legacy-v1\0");return e!==void 0&&r.update(At(e)),r.update(`\0${ge(t)}`),r.digest("hex")}function ge(t){let e=fe(t);return`${e.dev}:${e.ino}:${e.size}:${e.mtimeMs}`}function B(t,e){if(St(e.file)!==e.file||e.file==="."||e.file==="..")throw new Error("SQLite generation manifest contains an unsafe artifact path");return u(t,e.file)}function $(t,e){if(!w(t))return!1;let r=de(t);if(!r||r.size!==e.size)return!1;let n=`${t}\0${e.sha256}\0${r.identity}`;if(R.has(n))return!0;let i=Q(t,{inputKind:"immutable SQLite generation artifact",maxBytes:e.size}),o=de(t);if(!o||o.identity!==r.identity||i!==e.sha256)return!1;for(R.set(n,!0);R.size>Rt;){let s=R.keys().next().value;if(s===void 0)break;R.delete(s)}return!0}function de(t){let e=fe(t,{bigint:!0});return e.isFile()?{identity:`${e.dev}:${e.ino}:${e.size}:${e.mtimeNs}:${e.ctimeNs}`,size:Number(e.size)}:null}function Nt(t,e){return t.version===wt&&t.identity===e&&j(t.database)&&(t.index===void 0||j(t.index))&&(t.metadata===void 0||j(t.metadata))}function j(t){if(!t||typeof t!="object")return!1;let e=t;return typeof e.file=="string"&&!!e.file&&Number.isSafeInteger(e.size)&&(e.size??-1)>=0&&typeof e.sha256=="string"&&/^[a-f0-9]{64}$/.test(e.sha256)}function Gt(t){return t.version===kt&&typeof t.currentGeneration=="string"&&!!t.currentGeneration&&typeof t.publishedAt=="string"&&Number.isFinite(Date.parse(t.publishedAt))&&(t.artifactSet===void 0||t.artifactSet==="immutable-v1")&&_t(t.stableMirrors)&&qt(t.previousGeneration)&&Ct(t.publication)}function _t(t){if(t===void 0)return!0;if(!t||typeof t!="object")return!1;let e=t;return typeof e.databaseFileIdentity=="string"&&!!e.databaseFileIdentity&&(e.indexFileIdentity===void 0||typeof e.indexFileIdentity=="string"&&!!e.indexFileIdentity)}function qt(t){if(t===void 0)return!0;if(!t||typeof t!="object")return!1;let e=t;return typeof e.generationIdentity=="string"&&!!e.generationIdentity&&typeof e.databasePath=="string"&&!!e.databasePath&&(e.metadataPath===void 0||typeof e.metadataPath=="string"&&!!e.metadataPath)}function Ct(t){if(t===void 0)return!0;if(!t||typeof t!="object")return!1;let e=t,r=[e.converterDurationMs,e.affectedDocumentCount,e.changedDocumentCount,e.producerDurationMs,e.materializationDurationMs,e.patchDurationMs].filter(n=>n!==void 0);return(e.mode==="incremental"||e.mode==="full")&&e.validation==="passed"&&e.converterDurationMs!==void 0&&r.every(n=>typeof n=="number"&&Number.isFinite(n)&&n>=0)&&(e.scipCompanion===void 0||e.scipCompanion==="current"||e.scipCompanion==="deferred")&&(e.typescriptOverlayGeneration===void 0||typeof e.typescriptOverlayGeneration=="string"&&!!e.typescriptOverlayGeneration)&&(e.scipCompanion!=="deferred"||!!e.typescriptOverlayGeneration)&&(e.fallbackReason===void 0||typeof e.fallbackReason=="string")}import{execFileSync as Pe,spawnSync as Yr}from"child_process";import{platform as Bt}from"os";import{resolve as $t}from"path";var Se=Bt()==="win32";function Xr(t){let e=Se?"where":"which";try{return Pe(e,[t],{stdio:"pipe",timeout:1e4,killSignal:"SIGKILL"}),!0}catch{return!1}}var jt=/\.(?:c|m)?js$/i,Jt=/\.(?:exe|com)$/i;function Zr(t,e){return jt.test(t)?{binary:process.execPath,args:[t,...e]}:{binary:t,args:[...e]}}function Ut(t,e){return Pe(t,e,{stdio:["ignore","pipe","ignore"],encoding:"utf8",timeout:1e4,killSignal:"SIGKILL"})}function en(t,e={}){let r=e.isWindows??Se,n=e.lookup??Ut,i;try{i=n(r?"where":"which",[t])}catch{return null}let o=i.split(/\r?\n/).map(s=>s.trim()).filter(Boolean);if(!r){let s=o[0];return s?$t(s):null}return o.find(s=>Jt.test(s))??null}import{execFileSync as Ie}from"child_process";import{platform as zt}from"os";var Fe=1e3,Le=2*1024*1024,Wt=25;function sn(t,e,r=xe){let n=r.readIdentity(t),i=new Map;return n&&i.set(t,n),{rootPid:t,rootIdentity:n,ownsProcessGroup:e,knownMembers:i}}async function an(t,e,r=xe){if(!t.rootIdentity){let l=await h(t,e.gracefulMs+e.forceMs,r);return{reaped:l,reason:l?"terminated":"identity-unavailable",detail:l?void 0:`Could not establish the birth identity of process ${t.rootPid}.`}}let n=Re(t,r);if(n==="mismatch")return{reaped:!1,reason:"identity-mismatch",detail:`Process ${t.rootPid} no longer has the identity owned by this runner.`};if(n==="exited"&&!he(t,r))return{reaped:!0,reason:"terminated"};if(r.platform==="win32"){try{r.terminateWindowsTree(t.rootPid)}catch(c){let d=await h(t,e.forceMs,r);return{reaped:d,reason:d?"terminated":"signal-failed",detail:d?void 0:J(c)}}let l=await h(t,e.forceMs,r);return{reaped:l,reason:l?"terminated":"deadline"}}let i=ke(t,"SIGTERM",r);if(await h(t,e.gracefulMs,r))return{reaped:!0,reason:"terminated"};let s=ke(t,"SIGKILL",r);return await h(t,e.forceMs,r)?{reaped:!0,reason:"terminated"}:s?{reaped:!1,reason:s.reason,detail:s.detail}:i?{reaped:!1,reason:i.reason,detail:i.detail}:{reaped:!1,reason:"deadline",detail:`Process tree ${t.rootPid} did not exit before its termination deadline.`}}function Re(t,e){let r=e.readIdentity(t.rootPid);if(!r)return"exited";if(!t.rootIdentity||!p(t.rootIdentity,r))return"mismatch";t.knownMembers.set(t.rootPid,r);for(let n of e.listDescendantPids(t.rootPid)){let i=e.readIdentity(n);i&&t.knownMembers.set(n,i)}return"owned"}function ke(t,e,r){let n=Re(t,r);if(n==="mismatch")return{reason:"identity-mismatch",detail:`Process ${t.rootPid} changed identity before ${e}.`};if(n==="owned"&&t.ownsProcessGroup)try{return r.signal(-t.rootPid,e),null}catch(o){if(!we(o))return{reason:"signal-failed",detail:J(o)}}let i=null;for(let o of t.knownMembers.values()){let s=r.readIdentity(o.pid);if(!(!s||!p(o,s)))try{r.signal(o.pid,e)}catch(a){!we(a)&&i===null&&(i=J(a))}}return i===null?null:{reason:"signal-failed",detail:i}}async function h(t,e,r){let n=r.now()+e;for(;he(t,r);){if(r.now()>=n)return!1;await r.sleep(Math.min(Wt,Math.max(1,n-r.now())))}return!0}function he(t,e){if(!t.rootIdentity&&e.isProcessAlive(t.rootPid))return!0;for(let r of t.knownMembers.values()){let n=e.readIdentity(r.pid);if(n&&p(r,n))return!0}return!!(t.ownsProcessGroup&&e.isProcessGroupAlive(t.rootPid))}function Qt(t){let e=Kt(!1),r=new Map;for(let s of e.split(/\r?\n/)){let a=/^\s*(\d+)\s+(\d+)\s*$/.exec(s);if(!a)continue;let l=Number(a[1]),c=Number(a[2]),d=r.get(c)??[];d.push(l),r.set(c,d)}let n=[],i=[...r.get(t)??[]],o=new Set;for(;i.length>0;){let s=i.pop();o.has(s)||(o.add(s),n.push(s),i.push(...r.get(s)??[]))}return n}function Kt(t){return Ie("ps",["-axo",t?"pid=,ppid=,rss=":"pid=,ppid="],{encoding:"utf8",timeout:Fe,maxBuffer:Le,env:{...process.env,LC_ALL:"C",LANG:"C"},stdio:["ignore","pipe","ignore"]})}function we(t){return typeof t=="object"&&t!==null&&"code"in t&&t.code==="ESRCH"}function J(t){return t instanceof Error?t.message:String(t)}var xe={platform:zt(),now:Date.now,readIdentity:S,isProcessAlive(t){try{return process.kill(t,0),!0}catch(e){return typeof e=="object"&&e!==null&&"code"in e&&e.code==="EPERM"}},isProcessGroupAlive(t){if(this.platform==="win32")return!1;try{return process.kill(-t,0),!0}catch(e){return typeof e=="object"&&e!==null&&"code"in e&&e.code==="EPERM"}},listDescendantPids(t){if(this.platform==="win32")return[];try{return Qt(t)}catch{return[]}},signal(t,e){process.kill(t,e)},terminateWindowsTree(t){Ie("taskkill.exe",["/PID",String(t),"/T","/F"],{timeout:Fe,maxBuffer:Le,stdio:"ignore",windowsHide:!0})},async sleep(t){await new Promise(e=>setTimeout(e,t))}};export{L as a,p as b,S as c,x as d,X as e,Me as f,nr as g,Z as h,k as i,ze as j,br as k,q as l,it as m,C as n,xr as o,ce as p,Ar as q,kt as r,wt as s,It as t,Ft as u,I as v,ht as w,Ur as x,zr as y,ye as z,Tt as A,vt as B,Dt as C,Wr as D,At as E,ge as F,Xr as G,Zr as H,en as I,sn as J,an as K};
|
|
4
|
+
//# sourceMappingURL=chunk-MYUKI5VN.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{e as M}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{e as M}from"./chunk-PIZY2GX6.js";import{b as $}from"./chunk-BOJ5SVE2.js";import{a as p}from"./chunk-BGBBVSH4.js";import{l as I}from"./chunk-63MBA7EG.js";import{d as D}from"./chunk-MTDBHTSF.js";import{d as b,j as h,p as x,q as y,u as L}from"./chunk-5IZTXSOL.js";import{a as g,e as S}from"./chunk-I3U2FN2T.js";import{x as d}from"./chunk-DMQ7ZKJG.js";var B=new Set(D());function X(e,n={}){let{scope:s,minLoc:i=1,limit:r,scanLimit:c,maxShapeFrequency:a=12}=n,o=n.semantic!==!1,t=w(e,F(e,{scope:s,minLoc:i,scanLimit:c}),{semantic:o,maxShapeFrequency:a}),m=P(t);return r?m.slice(0,r):m}function F(e,n){let s=L(e,{scope:n.scope}).filter(i=>v(i)&&!e.isIgnored(i.relativePath)).filter(i=>p(i)>=n.minLoc);return typeof n.scanLimit=="number"&&n.scanLimit>0&&s.sort((i,r)=>p(r)-p(i)||i.relativePath.localeCompare(r.relativePath)),$(s,n.scanLimit)}function v(e){return!e.isFunctionLike||h(e.symbol)?!1:e.kind===null||B.has(e.kind)}function w(e,n,s){let i=[];for(let a of n){let o=G(e,a,s);o&&i.push({signature:o,definition:a,fn:z(a)})}let r=new Map;for(let a of i)r.set(a.signature,(r.get(a.signature)??0)+1);let c=new Map;for(let a of i){let o=C(a.fn.loc),t=(r.get(a.signature)??0)>s.maxShapeFrequency,m=t?M(e,a.definition):null;if(t&&!m)continue;let u=t?`${a.signature}\0body\0${m}`:`${a.signature}\0band\0${o}`,l=c.get(u)??{signature:a.signature,locBand:o,exactBody:t,functions:[]};l.functions.push(a.fn),c.set(u,l)}return[...c.values()]}function z(e){return{symbol:e.symbol,shortName:b(e.symbol),file:e.relativePath,startLine:e.startLine,endLine:e.endLine,loc:p(e)}}function P(e){let n=[];for(let s of e)s.functions.length>=2&&n.push(s);return n.sort((s,i)=>{let r=i.functions.length-s.functions.length;if(r!==0)return r;let c=s.functions.reduce((o,t)=>o+t.loc,0);return i.functions.reduce((o,t)=>o+t.loc,0)-c}),n}function C(e){return e<=5?"<=5":e<=20?"6-20":">20"}function G(e,n,s){if(s.semantic){let c=I(e,n);if(c)return c}let i=k(n.documentation),r=i?A(i):null;return r||E(N(e,n.relativePath,n.startLine,n.endLine,n.leaf),n.leaf)}function k(e){return x(y(e))}function N(e,n,s,i,r){let c=d(e,n);if(!c)return null;let a=c.split(/\r?\n/),o=O(a,s,i,r);for(let t of o){let m=Math.min(a.length-1,Math.max(t,t+4)),u="";for(let l=t;l<=m;l+=1){let f=a[l]?.trim();if(f&&(u=u?`${u} ${f}`:f,q(u)))return u}if(u&&u.includes("("))return u}return null}function q(e){let n=e.replace(/\s+/g," ").trim();return!n.includes("(")||S(n)>0?!1:/[;{]$/.test(n)||/\)\s*(?::\s*[^={]+)?\s*(?:=>|=|throws\b|where\b|$)/i.test(n)||/\)\s*As\s+.+$/i.test(n)}function A(e){if(!e||!e.trim())return null;let n=e.replace(/^```\w*\s*/,"").replace(/\s*```$/,"").replace(/^\(method\)\s*/,"").replace(/^\(property\)\s*/,"").replace(/^\(function\)\s*/,"").replace(/^\(class\)\s*/,"").replace(/^\(interface\)\s*/,"").replace(/^\(enum\)\s*/,"").replace(/^\(type alias\)\s*/,"").replace(/^\(const\)\s*/,"").replace(/^\(var\)\s*/,"").trim(),s=n.indexOf("(");return s===-1||(n=n.slice(s),n=n.replace(/\s+/g,"").toLowerCase(),n.length<3)?null:n}function E(e,n){if(!e||!e.trim())return null;let s=e.replace(/\s+/g," ").trim(),i=s.indexOf("(");if(i===-1)return null;let r=s.slice(0,i),a=new RegExp(`\\b${g(n)}\\b`,"i").exec(r);a&&typeof a.index=="number"&&(r=r.slice(0,a.index)),r=r.replace(/\b(public|private|protected|internal|final|static|abstract|sealed|virtual|override|async|suspend|inline|constexpr|consteval|constinit|const|pub|fn|function|def|sub|friend|shared|readonly|new|open|partial|export)\b/gi," ").replace(/\s+/g," ").trim();let o=R(s.slice(i)).replace(/\)\s*=\s*[\s\S]*$/,")").replace(/\s+throws\s+[^={]+$/i,"").replace(/\s+where\s+.+$/i,"").replace(/\s+/g," ").trim();if(!o.startsWith("("))return null;let t=`${r?`${r} `:""}${o}`.replace(/\s+/g,"").toLowerCase();return t.length>=3?t:null}function R(e){let n=0,s=0,i=0,r=0,c=null,a=!1;for(let o=0;o<e.length;o+=1){let t=e[o];if(c){if(a){a=!1;continue}if(t==="\\"){a=!0;continue}t===c&&(c=null);continue}if(t==='"'||t==="'"||t==="`"){c=t;continue}if(t==="(")n+=1;else if(t===")")n=Math.max(0,n-1);else if(t==="[")i+=1;else if(t==="]")i=Math.max(0,i-1);else if(t==="<")r+=1;else if(t===">")r=Math.max(0,r-1);else if(t==="{"){if(n===0&&i===0&&r===0)return e.slice(0,o);s+=1}else if(t==="}")s=Math.max(0,s-1);else if(t==="="&&e[o+1]===">"&&n===0&&s===0&&i===0&&r===0)return e.slice(0,o)}return e}function O(e,n,s,i){let r=g(i),c=new RegExp(`\\b${r}\\b\\s*\\(`,"i"),a=new RegExp(`\\bdef\\s+${r}\\b`,"i"),o=[],t=new Set,m=Math.max(0,Math.min(n,e.length-1)),u=Math.max(m,Math.min(e.length-1,Math.max(s,n+4)));for(let l=m;l<=u;l+=1){let f=e[l]??"";(c.test(f)||a.test(f))&&!t.has(l)&&(t.add(l),o.push(l))}for(let l=0;l<e.length;l+=1){let f=e[l]??"";(c.test(f)||a.test(f))&&!t.has(l)&&(t.add(l),o.push(l))}return o}export{X as a};
|
|
2
|
+
//# sourceMappingURL=chunk-N5C65OFK.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{a as
|
|
2
|
-
`).trim();return o.length<=2e3?o:`${o.slice(0,2e3).trimEnd()}...`}function A(t,n){return n.filter(e=>t.includes(e))}var ct=/<!--\s*scip-query:\s*snapshot\s*-->/i;function Z(t,n){if((t.config.docs?.snapshotPaths??[]).some(r=>
|
|
3
|
-
`).toLowerCase(),e=[],i=A(n,[".scipquery","declaredcouplings","suppression","suppressions","config","configuration","json"]);if(i.length>0)return e.push(`configuration/example terms near citation: ${i.join(", ")}`),{citationKind:"configuration-example",actionTier:"support",reasons:e};let r=A(n,["accepted","intentional","intentionally","retained","historical"]);if(r.length>0)return e.push(`intentional-record terms near citation: ${r.join(", ")}`),{citationKind:"intentional-record",actionTier:"support",reasons:e};let o=A(n,["command","cli","usage","example","run","workflow"]);return o.length>0?(e.push(`guide/reference terms near citation: ${o.join(", ")}`),{citationKind:"guide-reference",actionTier:"signal",reasons:e}):(e.push(t.length>0?"citation appears in prose without config or guide markers":"citation context unavailable"),{citationKind:"behavioral-claim",actionTier:"direct",reasons:e})}function dt(t,n,e){let i=T(t,n);if(!i&&!S(t.config.projectRoot,n))return[];let r=i.split(/\r?\n/),o=e.flatMap(ut),s=[];for(let c=0;c<r.length;c+=1){let a=r[c]??"";o.some(d=>a.includes(d))&&s.push(I(r,c))}return s}function ut(t){let n=t.split("/");return[t,`./${t}`,n.slice(-3).join("/"),n.slice(-2).join("/")].filter((e,i,r)=>e.length>0&&r.indexOf(e)===i)}function ft(t){switch(t){case"behavioral-claim":return"a behavioral doc claim";case"configuration-example":return"a configuration example";case"guide-reference":return"a guide reference";case"intentional-record":return"an intentional record"}}function gt(t,n){switch(t){case"behavioral-claim":return`Re-read ${n} and update the behavioral claim or citation.`;case"configuration-example":return`Verify the configuration example in ${n} still points at the intended file; update only if the example target changed.`;case"guide-reference":return`Verify the guide reference in ${n} still sends readers to the right implementation or command surface.`;case"intentional-record":return`Verify the intentional citation in ${n} is still meant to name this file.`}}function
|
|
4
|
-
${e}`.toLowerCase(),r=A(i,["historical note","historical record","history note","retrospective","postmortem","post-mortem","archived","archive","previously","legacy","recorded","record of","snapshot","as of","migration note","decision record"]);if(r.length>0)return{docIntent:"historical-note",reasons:[`historical-note terms: ${r.join(", ")}`]};let o=A(i,["current","standard","standards","must","should","policy","guide","guidance","workflow","contract","invariant","source of truth"]);return o.length>0?{docIntent:"current-guidance",reasons:[`current-guidance terms: ${o.join(", ")}`]}:{docIntent:"unknown",reasons:["no current-guidance or historical-note markers found"]}}function P(t,n,e=[]){let i=t==="co-change"||e.length===0?null:J.classifyCitation(e);return{actionTier:Tt(t,n.docIntent,i?.actionTier),docIntent:n.docIntent,docIntentReasons:n.reasons,...i?{citationKind:i.citationKind,citationKindReasons:i.reasons}:{}}}function Tt(t,n,e){return n==="historical-note"?"support":e||(t==="co-change"?"signal":"direct")}function At(t,n){let e=_(t,{historyMode:n}),i=e.commitHistory();if(!i)return null;let r=e.trackedFiles()??new Set,o=new Map,s=new Map,c=new Set;for(let a of i.commits){let d=[...new Set(a.files)],
|
|
5
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as q}from"./chunk-QOKYJ33H.js";import{a as _}from"./chunk-DEUGHURX.js";import{a as G}from"./chunk-QDCCHMVZ.js";import{h as F,n as O,o as L,p as H,r as K,u as z,w as $,x as T}from"./chunk-DMQ7ZKJG.js";import{d as X,h as U,j as S}from"./chunk-7HU2IJ2T.js";function I(t,n){let e=et(t,n)??it(t,n)??rt(t,n)??ot(t,n);return st(t,e,n)}function et(t,n){let e=-1,i=null;for(let r=0;r<=n;r+=1){let o=N(t[r]??"");o&&(i===null?(i=o,e=r):o===i&&(i=null,e=-1))}if(i===null||e<0)return null;for(let r=n+1;r<t.length;r+=1)if(N(t[r]??"")===i)return{start:e,end:r+1};return{start:e,end:t.length}}function N(t){let n=t.match(/^\s*(```+|~~~+)/);return n?n[1].startsWith("`")?"`":"~":null}function it(t,n){if(!w(t[n]??""))return null;let e=n;for(;e>0&&w(t[e-1]??"");)e-=1;let i=n+1;for(;i<t.length&&w(t[i]??"");)i+=1;return{start:e,end:i}}function w(t){let n=t.trim();return n.startsWith("|")&&n.endsWith("|")&&n.includes("|")}function rt(t,n){let e=n;for(;e>=0;){let o=t[e]??"";if(E(o)!==null)break;if(B(o)!==null)return null;e-=1}if(e<0)return null;let i=E(t[e]??"");if(i===null)return null;let r=e+1;for(;r<t.length;){let o=t[r]??"",s=E(o);if(s!==null){if(s<=i)break;r+=1;continue}if(B(o)!==null)break;r+=1}return{start:e,end:r}}function E(t){let n=t.match(/^(\s*)(?:[-*+]\s+|\d+[.)]\s+)/);return n?n[1].length:null}function ot(t,n){let e=t[n]??"";if(W(e)||e.trim().length===0)return{start:n,end:n+1};let i=n;for(;i>0&&V(t[i-1]??"");)i-=1;let r=n+1;for(;r<t.length&&V(t[r]??"");)r+=1;return{start:i,end:r}}function V(t){return B(t)===null}function B(t){return t.trim().length===0?"blank":W(t)?"heading":N(t)?"fence":w(t)?"table":E(t)!==null?"list":null}function W(t){return/^#{1,6}\s+/.test(t.trim())}function st(t,n,e){let{start:i,end:r}=n;if(r-i>40){let s=Math.floor(20);i=Math.max(i,e-s),r=Math.min(r,i+40),i=Math.max(n.start,r-40)}let o=t.slice(i,r).join(`
|
|
2
|
+
`).trim();return o.length<=2e3?o:`${o.slice(0,2e3).trimEnd()}...`}function A(t,n){return n.filter(e=>t.includes(e))}var ct=/<!--\s*scip-query:\s*snapshot\s*-->/i;function Z(t,n){if((t.config.docs?.snapshotPaths??[]).some(r=>G(r,n)))return!0;let i=T(t,n);return i.length>0&&ct.test(i)}var J={classifyCitation:lt,citationContexts:dt,citationKindLabel:ft,citationRemediation:gt,referenceTargets:ht,hasLineAnchoredCitation:at};function at(t){return t.some(n=>(n.lineReferences?.length??0)>0)}function lt(t){let n=t.join(`
|
|
3
|
+
`).toLowerCase(),e=[],i=A(n,[".scipquery","declaredcouplings","suppression","suppressions","config","configuration","json"]);if(i.length>0)return e.push(`configuration/example terms near citation: ${i.join(", ")}`),{citationKind:"configuration-example",actionTier:"support",reasons:e};let r=A(n,["accepted","intentional","intentionally","retained","historical"]);if(r.length>0)return e.push(`intentional-record terms near citation: ${r.join(", ")}`),{citationKind:"intentional-record",actionTier:"support",reasons:e};let o=A(n,["command","cli","usage","example","run","workflow"]);return o.length>0?(e.push(`guide/reference terms near citation: ${o.join(", ")}`),{citationKind:"guide-reference",actionTier:"signal",reasons:e}):(e.push(t.length>0?"citation appears in prose without config or guide markers":"citation context unavailable"),{citationKind:"behavioral-claim",actionTier:"direct",reasons:e})}function dt(t,n,e){let i=T(t,n);if(!i&&!S(t.config.projectRoot,n))return[];let r=i.split(/\r?\n/),o=e.flatMap(ut),s=[];for(let c=0;c<r.length;c+=1){let a=r[c]??"";o.some(d=>a.includes(d))&&s.push(I(r,c))}return s}function ut(t){let n=t.split("/");return[t,`./${t}`,n.slice(-3).join("/"),n.slice(-2).join("/")].filter((e,i,r)=>e.length>0&&r.indexOf(e)===i)}function ft(t){switch(t){case"behavioral-claim":return"a behavioral doc claim";case"configuration-example":return"a configuration example";case"guide-reference":return"a guide reference";case"intentional-record":return"an intentional record"}}function gt(t,n){switch(t){case"behavioral-claim":return`Re-read ${n} and update the behavioral claim or citation.`;case"configuration-example":return`Verify the configuration example in ${n} still points at the intended file; update only if the example target changed.`;case"guide-reference":return`Verify the guide reference in ${n} still sends readers to the right implementation or command surface.`;case"intentional-record":return`Verify the intentional citation in ${n} is still meant to name this file.`}}function ht(t,n,e){let i=q(e),r=new Set;for(let o of n)pt(t,o,i.get(o)??[])&&r.add(o);return r}function pt(t,n,e){if(!mt.test(n)||!S(t.config.projectRoot,n))return!0;if(e.length===0)return!1;let i=U(t.config.projectRoot,n,{inputKind:"changed source file"}).split(/\r?\n/),r=yt(i);for(let o of e)for(let s=o.startLine;s<=o.endLine;s+=1)if((i[s]??"").trim()!==""&&!r.has(s))return!0;return!1}var mt=/\.(?:[cm]?[jt]sx?)$/i;function yt(t){let n=new Set,e=!1;for(let i=0;i<t.length;i+=1){let r=t[i].trim();!e&&Ct(r)&&(e=!0),e&&(n.add(i),r.endsWith(";")&&(e=!1))}return n}function Ct(t){return/^import(?:\s|$)/.test(t)||/^export(?:\s+type)?\s+(?:\*|\{)/.test(t)}var Q=z({kind:"doc-path-evidence",invalidation:$("doc-path-evidence"),serialize:jt,deserialize:Lt}),v=/\.(?:md|mdx|rst|txt)$/i;function Dt(t){return/(?:^|\/)(?:docs\/plans|plans|adrs?|rfcs?|decisions|changelogs?|archive|reports?)\//i.test(t)||/(?:^|\/)CHANGELOG\.(?:md|mdx|rst|txt)$/i.test(t)}var bt=3,St=/([A-Za-z0-9_@-]+(?:\/[A-Za-z0-9_.@-]+)+\.[A-Za-z0-9]{1,6})(?::([1-9][0-9]*))?\b/g;function en(t,n={}){let{doc:e,limit:i=20,minCoupling:r=bt,includeSnapshotExcluded:o=!1}=n,s=At(t,n.historyMode??"bounded");if(!s)return{available:!1,commitsAnalyzed:0,docsScanned:0,findings:[]};let c=[];for(let a of s.docFiles){if(e!==void 0&&!a.includes(e)||e===void 0&&!Y(t,a)||e!==void 0&&!S(t.config.projectRoot,a))continue;let d=Z(t,a);if(d&&!o)continue;let{value:m,estimated:y}=xt(t,a,s.changeTimes.get(a)),g=Rt(t,a),u=new Map,{resolved:l,broken:h,citations:b}=wt(t,a,s.tracked,s.trackedBySuffix,s.everSeenInHistory),x=new Map(b.map(f=>[f.file,f]));for(let f of l){if(f===a||v.test(f))continue;let C=(s.changeTimes.get(f)??[]).filter(D=>D>m).length;if(C===0)continue;let p=x.get(f);u.set(f,{file:f,evidence:"reference",coChanges:0,changesSinceDocUpdate:C,...P("reference",g,p?.contexts),citationContexts:p?.contexts,citedLines:p?.lineReferences})}for(let[f,C]of s.coupling.get(a)??[]){if(C<r||!s.tracked.has(f))continue;let p=(s.changeTimes.get(f)??[]).filter(M=>M>m).length;if(p===0)continue;let D=u.get(f);D?(D.evidence="both",D.coChanges=C,Object.assign(D,P("both",g,D.citationContexts))):u.set(f,{file:f,evidence:"co-change",coChanges:C,changesSinceDocUpdate:p,...P("co-change",g)})}if(u.size===0&&h.length===0)continue;let R=[...u.values()].sort((f,C)=>C.changesSinceDocUpdate-f.changesSinceDocUpdate);c.push({doc:a,docLastChangedAt:m,staleness:R.reduce((f,C)=>f+C.changesSinceDocUpdate,0)+h.length*10,subjects:R.slice(0,8),brokenReferences:h,...d?{snapshotExcluded:!0}:{},...y?{docLastChangedAtEstimated:!0}:{}})}return c.sort((a,d)=>d.staleness-a.staleness),{available:!0,commitsAnalyzed:s.historyCommitCount,docsScanned:s.docFiles.length,findings:c.slice(0,i)}}function xt(t,n,e){if(e&&e.length>0)return{value:Math.max(...e),estimated:!1};try{return{value:Math.floor(X(t.config.projectRoot,n).mtimeMs/1e3),estimated:!0}}catch(i){if(S(t.config.projectRoot,n))throw i;return{value:0,estimated:!1}}}function Rt(t,n){let e=T(t,n).slice(0,6e3);if(!e)return{docIntent:"unknown",reasons:["doc text unavailable"]};let i=`${n}
|
|
4
|
+
${e}`.toLowerCase(),r=A(i,["historical note","historical record","history note","retrospective","postmortem","post-mortem","archived","archive","previously","legacy","recorded","record of","snapshot","as of","migration note","decision record"]);if(r.length>0)return{docIntent:"historical-note",reasons:[`historical-note terms: ${r.join(", ")}`]};let o=A(i,["current","standard","standards","must","should","policy","guide","guidance","workflow","contract","invariant","source of truth"]);return o.length>0?{docIntent:"current-guidance",reasons:[`current-guidance terms: ${o.join(", ")}`]}:{docIntent:"unknown",reasons:["no current-guidance or historical-note markers found"]}}function P(t,n,e=[]){let i=t==="co-change"||e.length===0?null:J.classifyCitation(e);return{actionTier:Tt(t,n.docIntent,i?.actionTier),docIntent:n.docIntent,docIntentReasons:n.reasons,...i?{citationKind:i.citationKind,citationKindReasons:i.reasons}:{}}}function Tt(t,n,e){return n==="historical-note"?"support":e||(t==="co-change"?"signal":"direct")}function At(t,n){let e=_(t,{historyMode:n}),i=e.commitHistory();if(!i)return null;let r=e.trackedFiles()??new Set,o=new Map,s=new Map,c=new Set;for(let a of i.commits){let d=[...new Set(a.files)],m=d.filter(g=>v.test(g)),y=d.filter(g=>!v.test(g));for(let g of d){c.add(g);let u=o.get(g)??[];u.push(a.timestamp),o.set(g,u)}for(let g of m){let u=s.get(g);u||(u=new Map,s.set(g,u));for(let l of y)u.set(l,(u.get(l)??0)+1)}}return{changeTimes:o,coupling:s,docFiles:[...r].filter(a=>v.test(a)),everSeenInHistory:c,historyCommitCount:i.commits.length,tracked:r,trackedBySuffix:tt(r)}}function rn(t,n){if(n.size===0)return[];let e=H(),i=0,r=0,o=0,s=0,c=0,a=0;return K("doc-reference.docs-citing-files",()=>{let d=_(t).trackedFiles()??new Set;i=d.size;let m=tt(d),y=Mt(n,m),g=[];for(let u of d){if(!Y(t,u))continue;e&&(r+=1);let l=T(t,u);if(!l&&!S(t.config.projectRoot,u)){e&&(o+=1);continue}if(!It(l,y)){e&&(s+=1);continue}let h=nt(t,u,l);if(!h)continue;e&&(c+=1);let b=vt(h.candidates,n,y,d,m);if(b.size===0)continue;let x=[...new Set([...b.values()].flatMap(p=>[...p]))],R=Et(h.contextsByCandidate,x),f=[...b].map(([p,D])=>({file:p,contexts:k([...D].flatMap(M=>R.get(M)??[])).slice(0,3),lineReferences:j([...D].flatMap(M=>h.lineReferencesByCandidate.get(M)??[]))})).filter(p=>p.contexts.length>0),C=[...b.keys()];if(C.length>0){e&&(a+=1);let p=C.sort();g.push({doc:u,cited:p,citations:f,citedClaims:k(f.flatMap(D=>D.contexts)).slice(0,3)})}}return g},()=>({targets:n.size,trackedFiles:i,livingDocs:r,unreadableDocs:o,candidateMisses:s,evidenceDocs:c,citedDocs:a}))}function Y(t,n){return v.test(n)&&!Dt(n)&&S(t.config.projectRoot,n)}function tt(t){let n=new Map;for(let e of t){let i=e.split("/");for(let r of[2,3]){if(i.length<r)continue;let o=i.slice(-r).join("/"),s=n.get(o)??[];s.push(e),n.set(o,s)}}return n}function Mt(t,n){let e=new Set(t);for(let i of t){let r=i.split("/");for(let o of[2,3]){if(r.length<o)continue;let s=r.slice(-o).join("/"),c=n.get(s);c?.length===1&&c[0]===i&&e.add(s)}}return e}function vt(t,n,e,i,r){let o=new Map;for(let s of t){if(!e.has(s))continue;let c;if(n.has(s))c=s;else if(i.has(s))c=s;else{let d=r.get(s);d?.length===1&&(c=d[0])}if(!c||!n.has(c))continue;let a=o.get(c)??new Set;a.add(s),o.set(c,a)}return o}function wt(t,n,e,i,r){let o=new Set,s=new Set,c=nt(t,n);if(!c)return{resolved:o,broken:[],citations:[]};let a=c.candidates,d=c.contextsByCandidate,m=c.lineReferencesByCandidate,y=new Map,g=new Map,u=(l,h)=>{let b=d.get(h);if(b&&b.length>0){let R=y.get(l)??[];R.push(...b),y.set(l,k(R).slice(0,3))}let x=m.get(h);x&&x.length>0&&g.set(l,j([...g.get(l)??[],...x]))};for(let l of a){if(e.has(l)){o.add(l),u(l,l);continue}let h=i.get(l);if(h&&h.length===1){o.add(h[0]),u(h[0],l);continue}h&&h.length>1||r.has(l)&&s.add(l)}return{resolved:o,broken:[...s],citations:[...y].map(([l,h])=>({file:l,contexts:h,lineReferences:g.get(l)}))}}function Et(t,n){let e=new Map;for(let i of n){let r=t.get(i);r&&r.length>0&&e.set(i,[...r])}return e}function nt(t,n,e){let i=e;if(i===void 0&&(i=T(t,n),!i&&!S(t.config.projectRoot,n)))return null;let r=F(t,n,i),o=Q.read(t,n,r);if(o)return o;let s=kt(i);return Q.write(t,n,r,s),s}function It(t,n){for(let e of n)if(t.includes(e))return!0;return!1}function kt(t){let n=t.split(/\r?\n/),e=new Set,i=new Map,r=new Map;for(let o=0;o<n.length;o+=1){let s=n[o]??"";for(let c of s.matchAll(St)){let a=(c[1]??"").replace(/^\.?\//,"");if(a.length===0)continue;e.add(a);let d=c[2]?Number(c[2]):null;d!==null&&Number.isSafeInteger(d)&&r.set(a,j([...r.get(a)??[],d]));let m=I(n,o);if(m.length===0)continue;let y=i.get(a)??[];y.push(m),i.set(a,k(y).slice(0,3))}}return{candidates:[...e],contextsByCandidate:i,lineReferencesByCandidate:r}}function jt(t){let n={candidates:t.candidates,contextsByCandidate:[...t.contextsByCandidate.entries()],lineReferencesByCandidate:[...t.lineReferencesByCandidate.entries()]};return JSON.stringify(n)}function Lt(t){try{let n=JSON.parse(t);if(!O(n))return null;let e=L(n.candidates),i=Nt(n.contextsByCandidate),r=_t(n.lineReferencesByCandidate);return!e||!i?null:{candidates:e,contextsByCandidate:new Map(i),lineReferencesByCandidate:new Map(r??[])}}catch{return null}}function _t(t){if(t===void 0)return[];if(!Array.isArray(t))return null;let n=[];for(let e of t){if(!Array.isArray(e)||e.length!==2||typeof e[0]!="string"||!Array.isArray(e[1]))return null;let i=[];for(let r of e[1]){if(typeof r!="number"||!Number.isSafeInteger(r))return null;i.push(r)}n.push([e[0],j(i)])}return n}function Nt(t){if(!Array.isArray(t))return null;let n=[];for(let e of t){if(!Array.isArray(e)||e.length!==2||typeof e[0]!="string")return null;let i=L(e[1]);if(!i)return null;n.push([e[0],i])}return n}function k(t){let n=[];for(let e of new Set(t))n.some(i=>Bt(i,e))||n.push(e);return n}function j(t){return[...new Set(t)].sort((n,e)=>n-e)}function Bt(t,n){if(t===n)return!0;let e=t.split(/\r?\n/).map(c=>c.trim()).filter(c=>c.length>0),i=n.split(/\r?\n/).map(c=>c.trim()).filter(c=>c.length>0),r=Math.min(e.length,i.length);if(r===0)return!1;if(r<3)return t.includes(n)||n.includes(t);let o=new Set(i),s=e.filter(c=>o.has(c)).length;return s>=3&&s/r>=.6}export{Dt as a,en as b,rn as c};
|
|
5
|
+
//# sourceMappingURL=chunk-O2RM7E7L.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{a as b}from"./chunk-3TNRNKAT.js";import{a as D}from"./chunk-VETXXOYU.js";import{c as C}from"./chunk-JVZNWJBH.js";import{a as I}from"./chunk-6BJ7SOY7.js";import{c as P}from"./chunk-ICUQONOG.js";import{b as F}from"./chunk-LPGDO2XA.js";import{f as M,g as S}from"./chunk-HEOMG7IM.js";import{d as g}from"./chunk-5IZTXSOL.js";function re(e,n={}){let t=new C(e).productionCallableDefinitions({scope:n.scope,requireCallableSymbol:!0,includeSuppressed:!0}),r=L(e,t),l=n.search?.trim().toLocaleLowerCase();return t.map(s=>j(e,s,r.get(s.symbolId)??[])).filter(s=>s!==null).map(s=>s.result).filter(s=>!l||T(s).includes(l)).sort(G)}function ie(e,n,o={}){let t=F(e,n);if(!t.match)return{kind:"missing",query:n};if(t.total>1)return{kind:"ambiguous",query:n,total:t.total,candidates:[{symbol:t.match.symbol,shortName:g(t.match.symbol),relativePath:t.match.relativePath,startLine:t.match.startLine},...t.candidates]};let r=new C(e),l=r.definitionsForFile(t.match.relativePath).find(a=>a.symbol===t.match.symbol);if(!l?.isFunctionLike)return{kind:"not-entry",query:n,symbol:t.match.symbol,shortName:g(t.match.symbol),file:t.match.relativePath,reason:"The resolved symbol is not a callable definition."};let s=L(e,[l]),f=j(e,l,s.get(l.symbolId)??[]);if(!f)return{kind:"not-entry",query:n,symbol:l.symbol,shortName:g(l.symbol),file:l.relativePath,reason:"The callable is neither an external root nor an uncalled callable on a detected entry surface."};let m=K(e,r,l),i=new Set(o.expand??[]),c=z(m,i),d=new Set(c.regions.filter(a=>a.expanded).map(a=>a.id)),p=[...i].filter(a=>!d.has(a)).sort();return{kind:"matched",query:n,entry:f.result,regions:c.regions,regionEdges:c.regionEdges,unmatchedExpansions:p,coverage:{completeWithinIndexedStaticCallEdges:!0,completeWithinSelectedStaticEvidence:!0,candidateReachabilityIncluded:m.edges.some(a=>a.evidenceStrength==="candidate"),dynamicDispatchRepresented:!1,symbolCount:m.symbols.length,symbolEdgeCount:m.edges.length,exactSymbolEdgeCount:m.edges.filter(a=>a.evidenceStrength==="exact").length,candidateSymbolEdgeCount:m.edges.filter(a=>a.evidenceStrength==="candidate").length,regionCount:c.regions.length,regionEdgeCount:c.regionEdges.length,externalCallCount:m.externalCalls.length}}}function L(e,n){let o=n.filter(t=>B(e,t.relativePath)||S(e,t.symbol,t.relativePath).length>0);return P(e,o,{semantic:!1,semanticEvidence:I})}function j(e,n,o){let t=$(e,n),r=t.length>0,l=B(e,n.relativePath)&&o.length===0;if(!r&&!l)return null;let s=[...t];return l&&s.push("entry-surface-without-indexed-caller"),{definition:n,result:{symbol:n.symbol,shortName:g(n.symbol),file:n.relativePath,startLine:n.startLine,endLine:n.endLine,documentation:n.documentation,confidence:r?"root":"candidate",evidence:s,indexedCallerCount:o.length}}}function B(e,n){return M(e,n)||/(?:^|\/)entry\.(?:ts|tsx|js|jsx|mjs|cjs)$/.test(n)}function $(e,n){let o=S(e,n.symbol,n.relativePath),t=[];return w(o,["package-surface-file","transitive-package-surface"])&&D(e,n)&&t.push("package-public-export"),o.includes("rust-public-library")&&t.push("rust-public-library"),o.includes("framework-entrypoint")&&t.push("framework-dispatched-export"),w(o,["configured-file","configured-path-prefix","configured-qualified-var","configured-symbol-pattern"])&&t.push("configured-entry-root"),t}function w(e,n){return n.some(o=>e.includes(o))}function T(e){return[e.symbol,e.shortName,e.file,e.documentation??"",...e.evidence].join(`
|
|
2
|
+
`).toLocaleLowerCase()}function G(e,n){return N(e.confidence)-N(n.confidence)||e.file.localeCompare(n.file)||e.startLine-n.startLine||e.symbol.localeCompare(n.symbol)}function N(e){return e==="root"?0:1}function K(e,n,o){let t=new Map([[o.symbol,0]]),r=new Map,l=new Map([[o.symbol,o]]),s=new Map,f=new Map,m=[o];for(;m.length>0;){let i=n.calleeMap(m,{additive:!1,semantic:!1}),c=[];for(let d of m){let p=t.get(d.symbol)??0;r.set(d.symbol,k(d,p));for(let a of i.get(d.symbolId)??[]){let y=W(n,a,l);if(!y){let R=O(d,a);f.set(J(R),R);continue}let u=p+1,h=t.get(y.symbol);(h===void 0||u<h)&&t.set(y.symbol,u),r.set(y.symbol,k(y,Math.min(u,h??u)));let v=q(d,y,a);s.set(H(v),v),h===void 0&&c.push(y)}}m=c}return{symbols:[...r.values()].sort(Q),edges:[...s.values()].sort(U),externalCalls:[...f.values()].sort(V)}}function W(e,n,o){let t=o.get(n.symbol);if(t)return t;let r=e.definitionsForFile(n.file).find(l=>l.symbol===n.symbol)??null;return r&&o.set(r.symbol,r),r}function k(e,n){return{symbol:e.symbol,shortName:g(e.symbol),file:e.relativePath,depth:n}}function q(e,n,o){return{fromSymbol:e.symbol,fromShortName:g(e.symbol),fromFile:e.relativePath,toSymbol:n.symbol,toShortName:g(n.symbol),toFile:n.relativePath,source:o.source,evidenceStrength:o.source==="scip-chunk"?"candidate":"exact"}}function O(e,n){return{fromSymbol:e.symbol,fromShortName:g(e.symbol),fromFile:e.relativePath,toSymbol:n.symbol,toShortName:g(n.symbol),reportedFile:n.file,source:n.source,evidenceStrength:n.source==="scip-chunk"?"candidate":"exact"}}function z(e,n){let o=b(e.symbols,i=>i.file),t=b(e.edges.filter(i=>i.fromFile===i.toFile),i=>i.fromFile),r=b(e.externalCalls,i=>i.fromFile),l=A(e.edges.filter(i=>i.fromFile!==i.toFile)),s=b(l,i=>i.toRegionId),f=b(l,i=>i.fromRegionId);return{regions:[...o.entries()].map(([i,c])=>{let d=x(i),p=n.has(d),a=t.get(i)??[],y=r.get(i)??[];return{id:d,file:i,minDepth:Math.min(...c.map(u=>u.depth)),symbolCount:c.length,internalEdgeCount:a.length,externalCallCount:y.length,incomingRegionIds:E((s.get(d)??[]).map(u=>u.fromRegionId)),outgoingRegionIds:E((f.get(d)??[]).map(u=>u.toRegionId)),expanded:p,symbols:p?c:[],internalEdges:p?a:[],externalCalls:p?y:[]}}).sort((i,c)=>i.minDepth-c.minDepth||i.file.localeCompare(c.file)),regionEdges:l}}function A(e){let n=new Map;for(let o of e){let t=`${o.fromFile}\0${o.toFile}`,r=n.get(t)??[];r.push(o),n.set(t,r)}return[...n.values()].map(o=>{let t=o[0];return{fromRegionId:x(t.fromFile),fromFile:t.fromFile,toRegionId:x(t.toFile),toFile:t.toFile,callCount:o.length,exactCallCount:o.filter(r=>r.evidenceStrength==="exact").length,candidateCallCount:o.filter(r=>r.evidenceStrength==="candidate").length,fromSymbols:E(o.map(r=>r.fromShortName)),toSymbols:E(o.map(r=>r.toShortName)),evidence:E(o.map(r=>r.source))}}).sort((o,t)=>o.fromFile.localeCompare(t.fromFile)||o.toFile.localeCompare(t.toFile))}function x(e){return`file:${e}`}function E(e){return[...new Set(e)].sort()}function H(e){return`${e.fromSymbol}\0${e.toSymbol}`}function J(e){return`${e.fromSymbol}\0${e.toSymbol}`}function Q(e,n){return e.depth-n.depth||e.file.localeCompare(n.file)||e.symbol.localeCompare(n.symbol)}function U(e,n){return e.fromFile.localeCompare(n.fromFile)||e.fromSymbol.localeCompare(n.fromSymbol)||e.toSymbol.localeCompare(n.toSymbol)}function V(e,n){return e.fromFile.localeCompare(n.fromFile)||e.fromSymbol.localeCompare(n.fromSymbol)||e.toSymbol.localeCompare(n.toSymbol)}export{re as a,ie as b};
|
|
3
|
+
//# sourceMappingURL=chunk-OFUBXBYX.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{d as y}from"./chunk-ZBNL3QCY.js";import{b as h,e as b}from"./chunk-VGRUM7JI.js";import{G as m,v as l}from"./chunk-SDPA5DKN.js";import{c as u,d as i,f as c}from"./chunk-DRENNWRG.js";import{basename as f}from"path";function g(t,o){let n=o.className,e=h(t,n);return e.match?e.total>1?{kind:"ambiguous",query:n,total:e.total,candidates:[p(e.match),...e.candidates]}:{kind:"matched",query:n,owner:L(e.match),methods:M(t,e.match)}:{kind:"missing",query:n,suggestions:b(t,n,5)}}function j(t,o){let n=g(t,{className:o});if(n.kind==="missing")throw new Error(`No class definition matched '${o}'.`);if(n.kind==="ambiguous"){let e=n.candidates.map(s=>`${s.relativePath}:${s.startLine+1}`).join(", ");throw new Error(`Class '${o}' is ambiguous across ${n.total} definitions (${e}). Qualify it with a path or exact SCIP symbol identity.`)}return n.methods}function M(t,o){let n=i(o.symbol),s=new y(t).definitionsForFile(o.relativePath).filter(r=>c(r.symbol)),a=s.filter(r=>r.parentTypeName===n||r.symbol.includes(n)),d=(a.length>0?a:S(f(o.relativePath))===n?s.filter(r=>r.symbol.includes("<invalid-global-code>")):[]).map(r=>({startLine:r.startLine,endLine:r.endLine,name:i(r.symbol)}));return l(o.relativePath)!=="clojure"?d:R(d,w(t,o))}function p(t){return{symbol:t.symbol,shortName:u(t.symbol),relativePath:t.relativePath,startLine:t.startLine}}function L(t){return{...p(t),endLine:t.endLine}}function S(t){return t.replace(/\.[^.]+$/,"")}function w(t,o){let n=i(o.symbol);return n?(m(t,o.relativePath)?.clojureMembers??[]).filter(e=>e.ownerName===n).map(e=>({startLine:e.startLine,endLine:e.endLine,name:e.memberName})):[]}function R(t,o){let n=new Map;for(let e of[...t,...o])n.set(`${e.name}:${e.startLine}:${e.endLine}`,e);return[...n.values()].sort((e,s)=>e.startLine-s.startLine||e.endLine-s.endLine)}export{g as a,j as b};
|
|
2
|
+
//# sourceMappingURL=chunk-OFY4HTMI.js.map
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import{M,N as _,a as A,c as F,j as G,k as b}from"./chunk-SDPA5DKN.js";import{b as I,f as S}from"./chunk-VWLIOEEF.js";import{e as m}from"./chunk-HGFDYOVB.js";var C=G({kind:"file-dependency-graph",invalidation:b("file-dependency-graph"),serialize:e=>JSON.stringify(e),deserialize:T}),x=I("file-dep-graph",{clearGroups:["whole-project"]});function Q(e,n,r){if(r.length===0)return[];let i=new Set(r),s=w(e),t=new Set;if(n==="forward")for(let c of i)for(let o of s.get(c)??[])i.has(o)||t.add(o);else for(let[c,o]of s)if(!i.has(c))for(let d of i)o.has(d)&&t.add(c);return[...t].sort()}function w(e,n,r={}){let i=r.scipEdges??"all-references",s=r.sourceEdges??"imports-only",t=N(n,i,s);return x.get(e,t,()=>{let c=new Set(S(e,{includeIgnored:!1})),o=F(e),d=0,a=0,u=null,O=!1,p=0,E=0,D=null;return m("file-dep-graph.product",()=>{if(o){let l=C.read(e,t,o);if(l){O=!0,D=l.construction;let y=$(l);return d=l.sourceFileCount,a=l.sourceEdgeCount,p=l.scipEdgeCount,E=y.size,u=l.sourceDependencyFingerprint,y}}let f=m("file-dep-graph.source-imports",()=>{let l=J(e,c,n,s);return d=l.files.length,a=l.edges.length,u=l.fingerprint,l},()=>({scope:n??null,sourceEdges:s,files:d,edges:a})),g=new Map,P=(l,y)=>h(e,g,c,l,y);m("file-dep-graph.scip-edges",()=>{for(let l of K(e,n,i))p=(p??0)+1,P(l.from_file,l.to_file)},()=>({scope:n??null,edges:p}));for(let l of f.edges)P(l.fromFile,l.toFile);return E=g.size,o&&(D="full",C.write(e,t,o,{version:2,construction:"full",sourceDependencyFingerprint:f.fingerprint,sourceFileCount:f.files.length,sourceEdgeCount:f.edges.length,scipEdgeCount:p,edgeCount:v(g),graph:R(g)})),g},()=>({scope:n??null,available:o!==null,hit:O,construction:D,files:d,sourceEdges:a,sourceEdgeMode:s,scipEdges:p,graphFiles:E,sourceDependencyFingerprint:u}))})}function X(e){let n=N(void 0,"all-references","imports-only"),r=w(e);return{cacheKey:n,graph:H(r)}}function Z(e,n,r){let i=F(e);if(!i)return!1;let s=N(void 0,"all-references","imports-only");if(n.cacheKey!==s)return!1;let t=new Set(S(e,{includeIgnored:!1})),c=new Set(r),o=new Map;for(let[d,a]of n.graph)if(!(c.has(d)||!t.has(d)))for(let u of a)h(e,o,t,d,u);for(let d of L(e,c,"all-references"))h(e,o,t,d.from_file,d.to_file);for(let d of c)if(t.has(d))for(let a of _(e,d))a.sourcePath&&h(e,o,t,d,a.sourcePath);return C.write(e,s,i,{version:2,construction:"carried",sourceDependencyFingerprint:null,sourceFileCount:t.size,sourceEdgeCount:null,scipEdgeCount:null,edgeCount:v(o),graph:R(o)}),!0}function J(e,n,r,i){let s=[],t=[];for(let c of n)if(!(r&&!c.includes(r))){s.push(c);for(let o of _(e,c))o.sourcePath&&t.push({fromFile:c,toFile:o.sourcePath});if(i==="imports-and-reexports")for(let o of M(e,c))o.sourcePath&&t.push({fromFile:c,toFile:o.sourcePath})}return{files:s,edges:t,fingerprint:k(s,t)}}function k(e,n){let r=n.map(i=>`${i.fromFile}\0${i.toFile}`).sort();return A(JSON.stringify({files:e,edges:r}))}function N(e,n,r){return`edge-mode-v4:${n}:${r}:${e??"<all>"}`}function R(e){return[...e].map(([n,r])=>[n,[...r].sort()]).sort(([n],[r])=>n.localeCompare(r))}function $(e){return new Map(e.graph.map(([n,r])=>[n,new Set(r)]))}function T(e){let n=JSON.parse(e);return j(n)?n:null}function j(e){if(!e||typeof e!="object")return!1;let n=e;return n.version===2&&(n.construction==="full"||n.construction==="carried")&&(n.sourceDependencyFingerprint===null||typeof n.sourceDependencyFingerprint=="string")&&typeof n.sourceFileCount=="number"&&(n.sourceEdgeCount===null||typeof n.sourceEdgeCount=="number")&&(n.scipEdgeCount===null||typeof n.scipEdgeCount=="number")&&typeof n.edgeCount=="number"&&Array.isArray(n.graph)&&n.graph.every(z)}function H(e){return new Map([...e].map(([n,r])=>[n,new Set(r)]))}function v(e){let n=0;for(let r of e.values())n+=r.size;return n}function z(e){return Array.isArray(e)&&e.length===2&&typeof e[0]=="string"&&Array.isArray(e[1])&&e[1].every(n=>typeof n=="string")}function K(e,n,r){let i=n?"AND d1.relative_path LIKE ?":"",s=n?[`%${n}%`]:[],t=r==="imports-only"?"AND m.role = 2":"AND m.role != 1";return e.all(`SELECT DISTINCT
|
|
2
|
+
d1.relative_path AS from_file,
|
|
3
|
+
d2.relative_path AS to_file
|
|
4
|
+
FROM mentions m
|
|
5
|
+
JOIN chunks c ON m.chunk_id = c.id
|
|
6
|
+
JOIN documents d1 ON c.document_id = d1.id
|
|
7
|
+
JOIN global_symbols gs ON m.symbol_id = gs.id
|
|
8
|
+
JOIN (
|
|
9
|
+
SELECT m2.symbol_id, c2.document_id
|
|
10
|
+
FROM mentions m2
|
|
11
|
+
JOIN chunks c2 ON m2.chunk_id = c2.id
|
|
12
|
+
WHERE m2.role = 1
|
|
13
|
+
GROUP BY m2.symbol_id
|
|
14
|
+
) sym_def ON sym_def.symbol_id = gs.id
|
|
15
|
+
JOIN documents d2 ON sym_def.document_id = d2.id
|
|
16
|
+
WHERE d1.id != d2.id
|
|
17
|
+
${t}
|
|
18
|
+
${e.pathExclusionsFor("d1","d2")}
|
|
19
|
+
${i}`,...s)}function L(e,n,r){let i=[...n].sort();if(i.length===0)return[];let s=r==="imports-only"?"AND m.role = 2":"AND m.role != 1",t=[];for(let c=0;c<i.length;c+=500){let o=i.slice(c,c+500),d=o.map(()=>"?").join(", ");t.push(...e.all(`SELECT DISTINCT
|
|
20
|
+
d1.relative_path AS from_file,
|
|
21
|
+
d2.relative_path AS to_file
|
|
22
|
+
FROM mentions m
|
|
23
|
+
JOIN chunks c ON m.chunk_id = c.id
|
|
24
|
+
JOIN documents d1 ON c.document_id = d1.id
|
|
25
|
+
JOIN global_symbols gs ON m.symbol_id = gs.id
|
|
26
|
+
JOIN (
|
|
27
|
+
SELECT m2.symbol_id, c2.document_id
|
|
28
|
+
FROM mentions m2
|
|
29
|
+
JOIN chunks c2 ON m2.chunk_id = c2.id
|
|
30
|
+
WHERE m2.role = 1
|
|
31
|
+
GROUP BY m2.symbol_id
|
|
32
|
+
) sym_def ON sym_def.symbol_id = gs.id
|
|
33
|
+
JOIN documents d2 ON sym_def.document_id = d2.id
|
|
34
|
+
WHERE d1.id != d2.id
|
|
35
|
+
${s}
|
|
36
|
+
${e.pathExclusionsFor("d1","d2")}
|
|
37
|
+
AND d1.relative_path IN (${d})`,...o))}return t}function h(e,n,r,i,s){if(i===s||e.isIgnored(i)||e.isIgnored(s)||!r.has(s))return;let t=n.get(i);t||(t=new Set,n.set(i,t)),t.add(s)}export{Q as a,w as b,X as c,Z as d};
|
|
38
|
+
//# sourceMappingURL=chunk-OIRWZIYL.js.map
|