@qwen-code/qwen-code 0.21.1-simplify-system-prompt.0 → 0.21.2-nightly.20260801.bc382c3ff
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/bundled/qc-helper/docs/configuration/model-providers.md +2 -0
- package/bundled/qc-helper/docs/configuration/settings.md +42 -30
- package/bundled/qc-helper/docs/features/channels/_meta.ts +2 -0
- package/bundled/qc-helper/docs/features/channels/github.md +146 -0
- package/bundled/qc-helper/docs/features/channels/gitlab.md +177 -0
- package/bundled/qc-helper/docs/features/channels/overview.md +61 -6
- package/bundled/qc-helper/docs/features/code-review.md +21 -1
- package/bundled/qc-helper/docs/features/commands.md +1 -0
- package/bundled/qc-helper/docs/features/hooks.md +186 -32
- package/bundled/qc-helper/docs/features/mcp.md +9 -1
- package/bundled/qc-helper/docs/features/memory.md +27 -0
- package/bundled/qc-helper/docs/features/scheduled-tasks.md +3 -1
- package/bundled/qc-helper/docs/features/skills.md +14 -0
- package/bundled/qc-helper/docs/features/sub-agents.md +75 -8
- package/bundled/qc-helper/docs/features/tool-use-summaries.md +7 -7
- package/bundled/qc-helper/docs/qwen-serve.md +32 -8
- package/bundled/qc-helper/docs/reference/keyboard-shortcuts.md +4 -4
- package/bundled/qc-helper/docs/support/troubleshooting.md +2 -1
- package/bundled/review/DESIGN.md +19 -0
- package/bundled/review/SKILL.md +120 -61
- package/chunks/MaxSizedBox-CDHTDITS.js +89 -0
- package/chunks/{StandaloneSessionPicker-O6RKBPU4.js → StandaloneSessionPicker-L63HUAHP.js} +76 -73
- package/chunks/{acp-startup-profiler-RV3IV562.js → acp-startup-profiler-3RICG2YW.js} +2 -2
- package/chunks/{acpAgent-HYFVXVDR.js → acpAgent-6WVVT2P3.js} +2147 -1009
- package/chunks/agent-KDM4CBOU.js +85 -0
- package/chunks/agent-headless-AS7K2K57.js +79 -0
- package/chunks/{anthropicContentGenerator-LXUXMOE7.js → anthropicContentGenerator-WCBYB6JG.js} +388 -37
- package/chunks/{artifact-tool-Y5T7GG7F.js → artifact-tool-ANV4CFCR.js} +4 -4
- package/chunks/{askUserQuestion-2H6747FR.js → askUserQuestion-MALEB47H.js} +4 -4
- package/chunks/bridge-JNEW6FES.js +95 -0
- package/chunks/{build-RV63TIRH.js → build-GDBLPA24.js} +1 -1
- package/chunks/{ca-25EDXPFZ.js → ca-4OJN75WT.js} +52 -6
- package/chunks/{channel-management-service-G74LFADV.js → channel-management-service-QOO7TD3T.js} +21 -6
- package/chunks/channel-settings-store-4CSMTR4L.js +92 -0
- package/chunks/{channel-worker-group-PTJIJSKC.js → channel-worker-group-ERSUOPIR.js} +10 -6
- package/chunks/{channel-worker-manager-WIMGM2FD.js → channel-worker-manager-X247YDQ7.js} +10 -6
- package/chunks/{channel-worker-supervisor-KUFTR6P5.js → channel-worker-supervisor-ORJIEEPP.js} +6 -5
- package/chunks/{chunk-LNARWLZQ.js → chunk-25QQVOCG.js} +5 -5
- package/chunks/{chunk-2OM7GEXO.js → chunk-2A6MHYIA.js} +3 -3
- package/chunks/{chunk-ER5LWJR6.js → chunk-2CTKGIFR.js} +3 -3
- package/chunks/{chunk-SQBYH7PX.js → chunk-2DNKEBXY.js} +1 -1
- package/chunks/{chunk-6GMVPFB2.js → chunk-2IIJTXYF.js} +45 -16
- package/chunks/{chunk-BPJSQIJX.js → chunk-2J3OJGTL.js} +0 -2
- package/chunks/chunk-2M5N3DHY.js +378 -0
- package/chunks/{chunk-CC4N4M36.js → chunk-2PNQQ4UR.js} +2 -2
- package/chunks/{chunk-E5TUC6CA.js → chunk-2UISUFHQ.js} +3 -3
- package/chunks/{chunk-PWTZEM3C.js → chunk-33FNCQSY.js} +3 -37
- package/chunks/{chunk-J56UI34H.js → chunk-3LGZEYOF.js} +4 -2
- package/chunks/{chunk-66RMLJHC.js → chunk-3MHPWQ2M.js} +590 -212
- package/chunks/{chunk-NL7LTRLR.js → chunk-3RXUYQJI.js} +54 -74
- package/chunks/{chunk-E5Z2AVNV.js → chunk-3SH53ANB.js} +0 -11
- package/chunks/{chunk-XHRTVPG2.js → chunk-3WXMXT7C.js} +22 -11
- package/chunks/{chunk-C3NS4F2Q.js → chunk-42IKVPST.js} +1 -1
- package/chunks/{chunk-M5JM7OSF.js → chunk-432XCUHF.js} +2 -3
- package/chunks/{chunk-5U4IPFBR.js → chunk-433VD3HX.js} +4 -4
- package/chunks/chunk-434YCHSV.js +2196 -0
- package/chunks/{chunk-DHHOYAPR.js → chunk-4LKVQFHM.js} +7 -7
- package/chunks/{chunk-IPUUTYMV.js → chunk-4NFY2S7N.js} +0 -33
- package/chunks/{chunk-J6D3VXCC.js → chunk-5UJ6A3CH.js} +158 -12
- package/chunks/{chunk-N3FAY5CM.js → chunk-5UZITEHA.js} +158 -5
- package/chunks/{chunk-A4UCTEB5.js → chunk-5WV5S2GT.js} +0 -1
- package/chunks/chunk-6FMJLI5M.js +1591 -0
- package/chunks/{chunk-6FGBXPWM.js → chunk-6O5DVH27.js} +38 -44
- package/chunks/{chunk-2RFKHEXL.js → chunk-6PLDPT2C.js} +1 -1
- package/chunks/{chunk-52O2CIUL.js → chunk-7IYLHTTM.js} +130 -5
- package/chunks/{chunk-5THCYPLO.js → chunk-7K2WTPQO.js} +15 -8
- package/chunks/{chunk-2Q3OT4OV.js → chunk-7MY2AR5A.js} +204 -81
- package/chunks/{chunk-YH6G52F2.js → chunk-A2A34TSB.js} +4 -4
- package/chunks/{chunk-3QMGYBFN.js → chunk-A5YZ3FA2.js} +2 -80
- package/chunks/{chunk-K4XWPEWB.js → chunk-A6SX5TAH.js} +4 -33
- package/chunks/{chunk-VYPFXUCB.js → chunk-AKA24BGO.js} +1 -1
- package/chunks/chunk-AQ37AY7B.js +93 -0
- package/chunks/{chunk-PANH4R3B.js → chunk-AQEWCKX4.js} +18 -12
- package/chunks/{chunk-LG4GZIVV.js → chunk-AYB4HSBI.js} +4 -4
- package/chunks/{chunk-PJIZUQVC.js → chunk-AZQ3DT76.js} +2 -2
- package/chunks/{chunk-2JZBVYTU.js → chunk-BFHXDAR7.js} +1 -8
- package/chunks/{chunk-2W3OOD4W.js → chunk-BGXZBI5B.js} +7 -4
- package/chunks/{chunk-2YZJCM5T.js → chunk-BKUN5QHP.js} +7 -7
- package/chunks/{chunk-UUUTRMI2.js → chunk-BV4QX43X.js} +1 -1
- package/chunks/{chunk-4M377AZG.js → chunk-C4L2MEIT.js} +6 -6
- package/chunks/{chunk-VV6XU5L7.js → chunk-CHCLO3M7.js} +19 -14
- package/chunks/{chunk-TOFQCPDC.js → chunk-CWEIMFFW.js} +14 -8
- package/chunks/{chunk-XVNQMZ2I.js → chunk-DGEIYUC3.js} +0 -1
- package/chunks/{chunk-BPZALHVR.js → chunk-DI35ZN7T.js} +1 -1
- package/chunks/{chunk-WDSWXQU3.js → chunk-DUIJ2IXG.js} +5 -13
- package/chunks/{chunk-3MSHSCSN.js → chunk-DVGTU5TC.js} +94 -4
- package/chunks/{chunk-RHLZR4E5.js → chunk-DYA25Y7U.js} +1 -1
- package/chunks/{chunk-MUP3T3AD.js → chunk-E4WHKETF.js} +32 -38
- package/chunks/{chunk-WBL3FJEU.js → chunk-FC4KQFCS.js} +1 -1
- package/chunks/{chunk-V6VRAM7B.js → chunk-FJHA23GM.js} +12 -12
- package/chunks/chunk-FYJ7W2PI.js +194 -0
- package/chunks/{chunk-INADJJGW.js → chunk-G7XXKQYS.js} +2 -2
- package/chunks/{chunk-LZEMEFKY.js → chunk-GALUTA2C.js} +1 -1
- package/chunks/{chunk-ML52PL6O.js → chunk-GB3AB7TR.js} +4374 -3779
- package/chunks/{chunk-SASBXAQL.js → chunk-GHJM2C2T.js} +6 -8
- package/chunks/{chunk-LS77BEZP.js → chunk-GLCZKT5V.js} +1 -5
- package/chunks/chunk-GOFAQQZA.js +132 -0
- package/chunks/{chunk-BJX6ZSUK.js → chunk-GTM6IHBB.js} +2 -2
- package/chunks/{chunk-TF2X2WCT.js → chunk-GVISB2OH.js} +2 -2
- package/chunks/{chunk-OKY7HXPG.js → chunk-H36SETQS.js} +2 -2
- package/chunks/{chunk-7FZEBPKS.js → chunk-H4346YW5.js} +39 -22
- package/chunks/{chunk-LNURQEMZ.js → chunk-H4DSRWAS.js} +24 -13
- package/chunks/{chunk-3JAQDSXN.js → chunk-H6MC6VQX.js} +290 -179
- package/chunks/{chunk-GZXCZHCT.js → chunk-I3G5JWBV.js} +1 -1
- package/chunks/{chunk-PR75REBZ.js → chunk-I5GNT6ZS.js} +18 -82
- package/chunks/{chunk-MVS3NS2N.js → chunk-I6FAHB4N.js} +28 -5
- package/chunks/{chunk-ZOIFNCKL.js → chunk-I7JDGNG6.js} +3 -23
- package/chunks/{chunk-OJGCZBB7.js → chunk-II6WPWHY.js} +41 -36
- package/chunks/{chunk-UH3WSE5L.js → chunk-J26HHFI5.js} +2 -7
- package/chunks/{chunk-S3TWXGKA.js → chunk-JE7KQ2UP.js} +4 -2
- package/chunks/{chunk-ZD6UTE4A.js → chunk-JELIWHXD.js} +1 -1
- package/chunks/{chunk-6PSLCFQ2.js → chunk-JRIDA5HF.js} +18 -9
- package/chunks/{chunk-W4CQXHT6.js → chunk-K4CGQN4Q.js} +1 -1
- package/chunks/{chunk-G4WFQUYQ.js → chunk-K5Q62CGR.js} +1 -1
- package/chunks/{chunk-JCW2R7WC.js → chunk-K623ENWT.js} +3 -79
- package/chunks/{chunk-T2NCM2ET.js → chunk-K6KS3LTN.js} +2 -749
- package/chunks/{chunk-DN6ZX5AY.js → chunk-KG22G46Y.js} +62 -15
- package/chunks/{chunk-L5UHQJTJ.js → chunk-KKN2IE7Q.js} +1 -1
- package/chunks/{chunk-63P4EL5V.js → chunk-KVUBYJDM.js} +2 -2
- package/chunks/{chunk-E5WH5O3C.js → chunk-KXSYDCP2.js} +4 -4
- package/chunks/{chunk-JALU3ZDU.js → chunk-LAPK3GLC.js} +212 -16
- package/chunks/chunk-LBOVL47Y.js +29 -0
- package/chunks/{chunk-FQK6JAFG.js → chunk-LBWNSLJK.js} +4 -4
- package/chunks/{chunk-3IXOIAKE.js → chunk-LL4U3BSH.js} +30 -10
- package/chunks/{chunk-B7QDM6Z7.js → chunk-LRJWFR6L.js} +4 -4
- package/chunks/{chunk-RWS5VYWC.js → chunk-M2F5PLOW.js} +1018 -484
- package/chunks/{chunk-HIJQF5B5.js → chunk-M744OFVE.js} +1 -1
- package/chunks/{chunk-I7XZ3RY5.js → chunk-MBKPUM5Y.js} +1 -1
- package/chunks/chunk-MISUEWB4.js +8749 -0
- package/chunks/{chunk-FNQ6T3CV.js → chunk-MOHAWIAW.js} +10 -7
- package/chunks/{chunk-FODK6UMO.js → chunk-MPHPFVKK.js} +0 -2
- package/chunks/{chunk-QY5MMZ6O.js → chunk-MSIVKDRC.js} +4 -4
- package/chunks/{record-artifact-RQKFYO5B.js → chunk-MYT7N6QH.js} +22 -7
- package/chunks/{chunk-JESCGQM3.js → chunk-NAVJD2PQ.js} +8 -7
- package/chunks/{chunk-DM4Q4JJH.js → chunk-NGWYUZZO.js} +68794 -83526
- package/chunks/{chunk-6OUGMXDC.js → chunk-NWNEANAT.js} +7 -7
- package/chunks/{chunk-PQNHRFJC.js → chunk-NYX53SV4.js} +0 -2
- package/chunks/{chunk-Z5BLYMZM.js → chunk-NZB4NDJL.js} +10 -10
- package/chunks/{chunk-SRZ6DXVG.js → chunk-O2ZYHG33.js} +47 -138
- package/chunks/chunk-O6GEWCJA.js +21 -0
- package/chunks/{chunk-PHVR5UUY.js → chunk-OBAIHYFT.js} +1 -1
- package/chunks/chunk-OCPBI7J5.js +18 -0
- package/chunks/{chunk-P5V4T7NK.js → chunk-OCRM53TT.js} +11 -3
- package/chunks/{chunk-V7RNNPGC.js → chunk-P5Y23G2L.js} +18 -1
- package/chunks/{chunk-KU5XMLDK.js → chunk-PDDYAXL2.js} +7 -1
- package/chunks/{chunk-L26JL52R.js → chunk-PGEGUNH5.js} +108 -68
- package/chunks/{chunk-2JM6GZ5D.js → chunk-PGP7Y3RQ.js} +8 -13
- package/chunks/{chunk-VFSJ5VRH.js → chunk-PHODQP2V.js} +6 -6
- package/chunks/{chunk-PSWQZHEA.js → chunk-PXA5AWHY.js} +1 -1
- package/chunks/{chunk-VDDGDZMA.js → chunk-QHWCP53L.js} +14 -7
- package/chunks/chunk-QL4TN4HS.js +59 -0
- package/chunks/{chunk-USTWD7QV.js → chunk-QMBEW7EW.js} +26 -16
- package/chunks/{chunk-U4VTUMMK.js → chunk-QONSRAEV.js} +1 -1
- package/chunks/{chunk-NH6KE4JX.js → chunk-QYPT3QUD.js} +3 -3
- package/chunks/{chunk-GDIPH4JY.js → chunk-RGJ4JWSU.js} +133 -50
- package/chunks/{chunk-BO4XCS7P.js → chunk-RPYYTL7E.js} +77 -94
- package/chunks/{chunk-6AM5D4ME.js → chunk-S6LOFUVP.js} +0 -12
- package/chunks/{chunk-B4UMZKMU.js → chunk-SK2UKB45.js} +1 -1
- package/chunks/{chunk-QPDRAXDJ.js → chunk-SWEBEXPI.js} +1 -1
- package/chunks/chunk-T26EAKDL.js +13 -0
- package/chunks/chunk-T3CHYWJZ.js +758 -0
- package/chunks/{chunk-U7TXFVUN.js → chunk-TFFMATHX.js} +120 -95
- package/chunks/{chunk-M4UKFCZ2.js → chunk-TNVKFQXQ.js} +616 -217
- package/chunks/{chunk-5I2IWRSH.js → chunk-TYERNYH4.js} +2 -2
- package/chunks/{chunk-VAK25FTU.js → chunk-U25CMJYY.js} +1 -1
- package/chunks/{chunk-A5L3JMUA.js → chunk-UH7Z7Y45.js} +18 -4
- package/chunks/{chunk-BRRAJXPA.js → chunk-UHQ3L6GC.js} +1 -1
- package/chunks/{chunk-HV3G62R6.js → chunk-UHTJC7O3.js} +1 -1
- package/chunks/{chunk-3SJ43L4W.js → chunk-UKZEXS6K.js} +8 -0
- package/chunks/{chunk-DM22XS4K.js → chunk-UOFFZNXV.js} +361 -17
- package/chunks/{chunk-FY3M44RD.js → chunk-URN76TKR.js} +3 -3
- package/chunks/{chunk-MSLKI6C2.js → chunk-UWLG4UCE.js} +139 -31
- package/chunks/{chunk-A6UO2C7C.js → chunk-UWSXFI6E.js} +167 -81
- package/chunks/{chunk-BYFNTGKI.js → chunk-VS3GXRNZ.js} +3703 -1399
- package/chunks/{chunk-TQCBGUHN.js → chunk-VWF42XC6.js} +5 -5
- package/chunks/{chunk-32MVHM4T.js → chunk-W7XZ3KP5.js} +1 -1
- package/chunks/{chunk-B6ZJ7SI6.js → chunk-WISQLM4Q.js} +1526 -1420
- package/chunks/{chunk-H5FFA6TH.js → chunk-WK4TJUEA.js} +16 -3
- package/chunks/{chunk-3HBZKBMQ.js → chunk-WP4HGHFG.js} +5 -5
- package/chunks/{chunk-BIQWWWJN.js → chunk-XC2VAFVZ.js} +1 -1
- package/chunks/{chunk-EPDRMGT4.js → chunk-XC656O42.js} +4 -28
- package/chunks/{chunk-COH43MRJ.js → chunk-XCGIMOLN.js} +27 -1
- package/chunks/{chunk-YAF5VNU7.js → chunk-XCLLRKY5.js} +4 -5
- package/chunks/chunk-XFDPIC4P.js +319 -0
- package/chunks/{chunk-KIUFNBHR.js → chunk-XSA5EKTJ.js} +1 -1
- package/chunks/{chunk-OHNBB4XR.js → chunk-YAVY33G4.js} +1 -1
- package/chunks/{chunk-DLWL3Z7A.js → chunk-YXEVDA66.js} +3 -3
- package/chunks/chunk-Z4X5MTRT.js +133 -0
- package/chunks/{chunk-UW5EOVUN.js → chunk-ZBVS26BY.js} +4 -4
- package/chunks/{chunk-HTO4JFDZ.js → chunk-ZPJWUGCS.js} +0 -1
- package/chunks/{chunk-ZE5WPL4I.js → chunk-ZRFJ75D7.js} +3 -3
- package/chunks/{chunk-MK7VQDN3.js → chunk-ZTN6OA5J.js} +8 -6
- package/chunks/{computer-use-DOFAHZAB.js → computer-use-Z4NCIIJN.js} +54 -51
- package/chunks/{config-utils-VFQXVGNR.js → config-utils-64LM6OEQ.js} +4 -4
- package/chunks/contextCommand-HVM7XFCB.js +84 -0
- package/chunks/core-runtime-NL3ZBHBU.js +138 -0
- package/chunks/{create-sub-session-IWW2IZ2T.js → create-sub-session-AM32K2HD.js} +3 -3
- package/chunks/{create-sub-session-7543K2QA.js → create-sub-session-XHSCDYFU.js} +54 -51
- package/chunks/{cron-create-YIID5XAW.js → cron-create-HPXYE6C5.js} +6 -6
- package/chunks/{cron-delete-ZVHYCEP2.js → cron-delete-FPVNTKPK.js} +5 -5
- package/chunks/{cron-list-XEGS463Q.js → cron-list-ZEI6PAAV.js} +6 -6
- package/chunks/{daemon-VOMQW7KZ.js → daemon-PCNCI5YU.js} +239 -18
- package/chunks/daemon-status-provider-XD23SNAM.js +94 -0
- package/chunks/daemon-trust-policy-NOHK7IW5.js +89 -0
- package/chunks/daemon-trust-policy-monitor-ZBTSR333.js +176 -0
- package/chunks/{de-HGRCYDEJ.js → de-A6TI4LBB.js} +52 -6
- package/chunks/deferred-core-runtime-JJBHKM2C.js +93 -0
- package/chunks/{dist-RTJFMNEZ.js → dist-4LAMY2SK.js} +1449 -14
- package/chunks/{dist-NNVBBOGU.js → dist-4T4NCJFL.js} +2 -2
- package/chunks/dist-7KOL6OMD.js +13467 -0
- package/chunks/{dist-BRB6EXK4.js → dist-BH76AT7N.js} +3 -3
- package/chunks/dist-BXA3JXVQ.js +4749 -0
- package/chunks/{dist-KTYYJ2C5.js → dist-OEEFI6UU.js} +12 -9
- package/chunks/{dist-K6Y4E7FX.js → dist-SMLVOWKV.js} +5 -4
- package/chunks/{dist-ANLAT3GS.js → dist-V2RK6S6Q.js} +2 -1
- package/chunks/earlyInputCapture-KLAZDAIP.js +86 -0
- package/chunks/{edit-RIEOJWKB.js → edit-YQZWCISX.js} +53 -50
- package/chunks/{en-MTWBNGDO.js → en-RESOFG55.js} +55 -6
- package/chunks/{enter-worktree-OGK5FQ3R.js → enter-worktree-WLVWI3FP.js} +53 -50
- package/chunks/{enterPlanMode-IWZYALIB.js → enterPlanMode-6RYXFQUD.js} +53 -50
- package/chunks/environment-DXJTXSVT.js +106 -0
- package/chunks/errors-XGAGG2S2.js +92 -0
- package/chunks/esm-K5FARBNI.js +5548 -0
- package/chunks/{exit-worktree-4TEYVIVP.js → exit-worktree-C4276VPP.js} +53 -50
- package/chunks/exitPlanMode-MM5HIRUF.js +77 -0
- package/chunks/{fast-path-HYE7IFEV.js → fast-path-PIXYOHCH.js} +17 -3
- package/chunks/{fr-45RLL55O.js → fr-QF7RI5ZE.js} +52 -6
- package/chunks/{gemini-NGRQX3YJ.js → gemini-43RLVUNP.js} +171 -109
- package/chunks/{geminiContentGenerator-FQHPFZSR.js → geminiContentGenerator-PNQ4TSID.js} +7 -7
- package/chunks/{getMachineId-bsd-V7W3GODC.js → getMachineId-bsd-FG7IUY6U.js} +1 -1
- package/chunks/{getMachineId-darwin-TDO75DQP.js → getMachineId-darwin-GLCJI2RA.js} +1 -1
- package/chunks/{getMachineId-linux-TF43WQT2.js → getMachineId-linux-O6OPPAKO.js} +1 -1
- package/chunks/{getMachineId-unsupported-ZGUO3TXT.js → getMachineId-unsupported-S6CKYVGC.js} +1 -1
- package/chunks/{getMachineId-win-ECFYZZFQ.js → getMachineId-win-X5SRNEH7.js} +1 -1
- package/chunks/{glob-FRTM3X2E.js → glob-ZMBQKAU5.js} +53 -50
- package/chunks/goal-tools-Y767F7LZ.js +335 -0
- package/chunks/{grep-RKWVROCW.js → grep-HSV37W2Q.js} +55 -51
- package/chunks/handleAutoUpdate-QDHZPBAY.js +85 -0
- package/chunks/i18n-ME22A6RN.js +101 -0
- package/chunks/{image-gen-WIEM7KZA.js → image-gen-IFC7ZWSB.js} +12 -12
- package/chunks/initializer-J7H2CHVB.js +90 -0
- package/chunks/installationInfo-R7FXPQN5.js +84 -0
- package/chunks/{ja-B7DF7DFG.js → ja-URQESVGW.js} +52 -6
- package/chunks/{keychain-token-storage-MDTG3WRM.js → keychain-token-storage-7BT4TQ2A.js} +3 -3
- package/chunks/{kittyProtocolDetector-MBRTDRBK.js → kittyProtocolDetector-BFLAKYXH.js} +1 -1
- package/chunks/lib-RUF3WZA6.js +9 -0
- package/chunks/list-OYDIBA4N.js +93 -0
- package/chunks/{list-agents-5KJJHR6I.js → list-agents-GATIBBQQ.js} +3 -3
- package/chunks/loadedSettingsAdapter-OK6GK2GE.js +87 -0
- package/chunks/{loggingContentGenerator-WGM27QAW.js → loggingContentGenerator-U4ZEG4GL.js} +66 -50
- package/chunks/{loop-wakeup-FXKNNYSY.js → loop-wakeup-3DZMQQQQ.js} +15 -8
- package/chunks/{ls-NTK6VOQJ.js → ls-7F4GHXIH.js} +5 -5
- package/chunks/{lsp-2JI24STP.js → lsp-6FEHVBWI.js} +3 -3
- package/chunks/{managed-npm-update-JQ2CG3RH.js → managed-npm-update-PGKAJLLO.js} +52 -49
- package/chunks/mcp-S4DXJD2G.js +87 -0
- package/chunks/{monitor-7FEWXX5F.js → monitor-E5ZFMT74.js} +53 -50
- package/chunks/nonInteractiveCli-HNOHKEPE.js +149 -0
- package/chunks/{notebook-edit-JGJV2K6J.js → notebook-edit-6QDN6VZJ.js} +53 -50
- package/chunks/{openaiContentGenerator-JPVXDTAO.js → openaiContentGenerator-3NLB2C5O.js} +25 -27
- package/chunks/pidfile-ZMOIUGG6.js +90 -0
- package/chunks/process-registry-2CHQBXH5.js +157 -0
- package/chunks/{processUtils-V2LCK6T6.js → processUtils-E4QGQVWW.js} +2 -2
- package/chunks/{pt-22Q3FP73.js → pt-EEEQXRUI.js} +52 -6
- package/chunks/{qwenContentGenerator-TICV2W2Z.js → qwenContentGenerator-2LFRWJTM.js} +57 -54
- package/chunks/{qwenOAuth2-XGFI5XJG.js → qwenOAuth2-N32BUQDC.js} +10 -10
- package/chunks/read-file-GLDCWZBG.js +29 -0
- package/chunks/{read-mcp-resource-4DKQWGHD.js → read-mcp-resource-AFS3UKZO.js} +4 -4
- package/chunks/record-artifact-ECZSCEG5.js +21 -0
- package/chunks/resumeHistoryUtils-F5BE5QDW.js +95 -0
- package/chunks/ripGrep-T23Y4AGY.js +77 -0
- package/chunks/{ru-FZCNZHDC.js → ru-WGZDYQAB.js} +52 -6
- package/chunks/{run-qwen-serve-3VCV4I7E.js → run-qwen-serve-TI2HGLLU.js} +1155 -272
- package/chunks/runtime-WCWM3DO7.js +125 -0
- package/chunks/{scheduler-RS2I6RU5.js → scheduler-2QZO5AV5.js} +51 -48
- package/chunks/{sdk-exporters-grpc-AK3LGHNO.js → sdk-exporters-grpc-54L4LS5L.js} +4 -4
- package/chunks/{sdk-exporters-http-FS6ZV7MF.js → sdk-exporters-http-IKNWQJNV.js} +7 -7
- package/chunks/{sdk-impl-7FZSCSXB.js → sdk-impl-7CUUMQDB.js} +10 -10
- package/chunks/{send-message-Q6OOR6BR.js → send-message-X7G2JSII.js} +8 -13
- package/chunks/serve-DZOMYUFU.js +93 -0
- package/chunks/{server-HRZ23U7M.js → server-N4AJRKIQ.js} +5299 -1584
- package/chunks/{session-7XHZKTVV.js → session-GS6AKMN7.js} +167 -102
- package/chunks/{settings-7ZGZDXAS.js → settings-CUN3SELH.js} +56 -53
- package/chunks/shell-NGBFVXC5.js +87 -0
- package/chunks/{skill-LIWXNLDW.js → skill-SC2BSO75.js} +35 -23
- package/chunks/skill-settings-XVPCPW5K.js +95 -0
- package/chunks/spawnChannel-RILO4YY3.js +86 -0
- package/chunks/standalone-update-TMLT6LVJ.js +96 -0
- package/chunks/{startInteractiveUI-IW3CSKHA.js → startInteractiveUI-J45WOEOU.js} +1343 -1230
- package/chunks/{syntheticOutput-I3757IWH.js → syntheticOutput-FHRY3BPQ.js} +4 -4
- package/chunks/task-create-LAQXBIHC.js +26 -0
- package/chunks/{task-list-FOPULZEP.js → task-list-V6K5DRDH.js} +8 -8
- package/chunks/{task-stop-H6RHXFVQ.js → task-stop-LQXE52L6.js} +3 -3
- package/chunks/{task-update-M57TFZJT.js → task-update-NXRCXSPB.js} +13 -12
- package/chunks/{team-create-O2FROQ4R.js → team-create-W3EVWCTA.js} +55 -52
- package/chunks/{team-delete-QE2UXJL7.js → team-delete-Z4KGO7RC.js} +8 -8
- package/chunks/{team-plan-approval-Q6WDBXTQ.js → team-plan-approval-URYVKJF4.js} +53 -50
- package/chunks/theme-manager-CUAMS2NI.js +81 -0
- package/chunks/{todoWrite-VQ7FKOHL.js → todoWrite-OFIZDI7P.js} +34 -6
- package/chunks/{tool-search-APECNQ3Z.js → tool-search-DCICFL32.js} +21 -22
- package/chunks/total-session-admission-3ZTAXVUK.js +89 -0
- package/chunks/{tree-sitter-FS4VPMZA.js → tree-sitter-4D7QS7F6.js} +1 -1
- package/chunks/{tree-sitter-bash-6B46JJCV.js → tree-sitter-bash-VEJGF5XF.js} +1 -1
- package/chunks/trustedFolders-EVCN36O5.js +99 -0
- package/chunks/{update-relaunch-ON5MDJQG.js → update-relaunch-XLW46RHQ.js} +5 -5
- package/chunks/updateCheck-ZHVXDAIH.js +96 -0
- package/chunks/useAutoAcceptIndicator-ZGD6BJSP.js +97 -0
- package/chunks/{validateNonInterActiveAuth-JBLKBKRD.js → validateNonInterActiveAuth-R3BAQFDY.js} +102 -97
- package/chunks/{version-LTNUBQJY.js → version-PMWREGCG.js} +1 -1
- package/chunks/{web-fetch-L5UTI53V.js → web-fetch-PGN27SGF.js} +19 -21
- package/chunks/{web-search-KM33JOS3.js → web-search-KW4UNMRE.js} +13 -13
- package/chunks/{workflow-K7FAWV77.js → workflow-SN3TJBTJ.js} +374 -323
- package/chunks/workspace-providers-status-O3HUZGGR.js +90 -0
- package/chunks/{workspace-registration-store-6TGVDJV5.js → workspace-registration-store-M3FJ74RS.js} +2 -2
- package/chunks/workspace-registry-U7ISW23N.js +97 -0
- package/chunks/workspace-service-VH6IWADT.js +104 -0
- package/chunks/workspace-skills-status-XANARSZS.js +90 -0
- package/chunks/workspace-trust-reconciler-35EFR4GC.js +350 -0
- package/chunks/write-file-NCRSGUDT.js +79 -0
- package/chunks/xterm-headless-NTYVIBT3.js +3475 -0
- package/chunks/{zh-LUIGBD55.js → zh-OHX23Q44.js} +52 -6
- package/chunks/{zh-TW-F5KG2IYD.js → zh-TW-4G7YKDAQ.js} +52 -6
- package/chunks/zoom-image-X7CIADYC.js +224 -0
- package/cli.js +55 -48
- package/locales/ca.js +67 -6
- package/locales/de.js +69 -6
- package/locales/en.js +69 -6
- package/locales/fr.js +71 -6
- package/locales/ja.js +68 -6
- package/locales/pt.js +67 -6
- package/locales/ru.js +70 -6
- package/locales/zh-TW.js +62 -6
- package/locales/zh.js +62 -6
- package/package.json +5 -4
- package/web-shell/assets/{arc-BbHijhiN.js → arc-CaMTqKio.js} +1 -1
- package/web-shell/assets/{architectureDiagram-3BPJPVTR-Cb4B_JD0.js → architectureDiagram-3BPJPVTR-Bjxztij2.js} +1 -1
- package/web-shell/assets/{blockDiagram-GPEHLZMM-Dsjlh3H-.js → blockDiagram-GPEHLZMM-BYJzeHi9.js} +1 -1
- package/web-shell/assets/{c4Diagram-AAUBKEIU-Cp5AeR4U.js → c4Diagram-AAUBKEIU-fYAa-Eil.js} +1 -1
- package/web-shell/assets/channel-LEZei0-5.js +1 -0
- package/web-shell/assets/{chunk-2J33WTMH-CLcY7W2e.js → chunk-2J33WTMH-B1OTlTml.js} +1 -1
- package/web-shell/assets/{chunk-4BX2VUAB-BUhvY2LR.js → chunk-4BX2VUAB-DNj4uy6k.js} +1 -1
- package/web-shell/assets/{chunk-55IACEB6-kDIFC_71.js → chunk-55IACEB6-DAqNmg3c.js} +1 -1
- package/web-shell/assets/{chunk-727SXJPM-CIBO15f2.js → chunk-727SXJPM-BwB4ddxE.js} +1 -1
- package/web-shell/assets/{chunk-AQP2D5EJ-BJ_T_slV.js → chunk-AQP2D5EJ-DmHR_UZs.js} +1 -1
- package/web-shell/assets/{chunk-FMBD7UC4-BEkW35J8.js → chunk-FMBD7UC4-BlfOXumo.js} +1 -1
- package/web-shell/assets/{chunk-ND2GUHAM-GGPxofay.js → chunk-ND2GUHAM-BKogiSy7.js} +1 -1
- package/web-shell/assets/{chunk-QZHKN3VN-Bifllrb6.js → chunk-QZHKN3VN-DEclVrOF.js} +1 -1
- package/web-shell/assets/classDiagram-4FO5ZUOK-BiaRhfvf.js +1 -0
- package/web-shell/assets/classDiagram-v2-Q7XG4LA2-BiaRhfvf.js +1 -0
- package/web-shell/assets/{cose-bilkent-S5V4N54A-C-Add_Dp.js → cose-bilkent-S5V4N54A-CwtS21WT.js} +1 -1
- package/web-shell/assets/{dagre-BM42HDAG-B7MfwNq2.js → dagre-BM42HDAG-BAAIlB4p.js} +1 -1
- package/web-shell/assets/{diagram-2AECGRRQ-CY_0zuDz.js → diagram-2AECGRRQ-ChljtF_V.js} +1 -1
- package/web-shell/assets/{diagram-5GNKFQAL-VyYSbCgA.js → diagram-5GNKFQAL-BIXVd31-.js} +1 -1
- package/web-shell/assets/{diagram-KO2AKTUF-CBiIZ2PL.js → diagram-KO2AKTUF-BEiBaS15.js} +1 -1
- package/web-shell/assets/{diagram-LMA3HP47-BL3CrVOx.js → diagram-LMA3HP47-C-g4tWKM.js} +1 -1
- package/web-shell/assets/{diagram-OG6HWLK6-CZUPx96P.js → diagram-OG6HWLK6-CNCCbNQG.js} +1 -1
- package/web-shell/assets/{erDiagram-TEJ5UH35-B81xHr1-.js → erDiagram-TEJ5UH35-v8ysnsdI.js} +1 -1
- package/web-shell/assets/{flowDiagram-I6XJVG4X-EZWhir-J.js → flowDiagram-I6XJVG4X-LKVlLjwA.js} +1 -1
- package/web-shell/assets/{ganttDiagram-6RSMTGT7-CVFSuIAg.js → ganttDiagram-6RSMTGT7-DA5MrKYG.js} +1 -1
- package/web-shell/assets/{gitGraphDiagram-PVQCEYII-C1H2uQDv.js → gitGraphDiagram-PVQCEYII-Cyg5fe6d.js} +1 -1
- package/web-shell/assets/index-BgOcEaVt.js +1756 -0
- package/web-shell/assets/index-C2GE3DAF.js +74 -0
- package/web-shell/assets/{index-BYo99NBH.js → index-CKdUkVVS.js} +1 -1
- package/web-shell/assets/index-DA5Lvscv.css +5 -0
- package/web-shell/assets/{infoDiagram-5YYISTIA-BwyFMlF8.js → infoDiagram-5YYISTIA-SLsfu3Qd.js} +1 -1
- package/web-shell/assets/{ishikawaDiagram-YF4QCWOH-CQ7Yhn2Y.js → ishikawaDiagram-YF4QCWOH-CmHOmTNx.js} +1 -1
- package/web-shell/assets/{journeyDiagram-JHISSGLW-CJn2sf0l.js → journeyDiagram-JHISSGLW-C3gM_HFQ.js} +1 -1
- package/web-shell/assets/{kanban-definition-UN3LZRKU-DaNRqwVN.js → kanban-definition-UN3LZRKU-BbHD7duM.js} +1 -1
- package/web-shell/assets/{linear-DCKODZe2.js → linear-CSBvm435.js} +1 -1
- package/web-shell/assets/{mermaid.core-CTGJOk27.js → mermaid.core-CPMw15lU.js} +5 -5
- package/web-shell/assets/{mindmap-definition-RKZ34NQL-BKU3_3rg.js → mindmap-definition-RKZ34NQL-C_tNqXQW.js} +1 -1
- package/web-shell/assets/{pieDiagram-4H26LBE5-COcwBJ82.js → pieDiagram-4H26LBE5-DH_N-8yY.js} +1 -1
- package/web-shell/assets/{quadrantDiagram-W4KKPZXB-CQnQ443x.js → quadrantDiagram-W4KKPZXB-CRbS8UkN.js} +1 -1
- package/web-shell/assets/{requirementDiagram-4Y6WPE33-CZ2oj5cD.js → requirementDiagram-4Y6WPE33-DJgdZPZn.js} +1 -1
- package/web-shell/assets/{sankeyDiagram-5OEKKPKP-BxAv5mNu.js → sankeyDiagram-5OEKKPKP-vhL1y5zx.js} +1 -1
- package/web-shell/assets/{sequenceDiagram-3UESZ5HK-CztaySPs.js → sequenceDiagram-3UESZ5HK-UQthhFwd.js} +1 -1
- package/web-shell/assets/{stateDiagram-AJRCARHV-CTQT1oGD.js → stateDiagram-AJRCARHV-CAywEm20.js} +1 -1
- package/web-shell/assets/stateDiagram-v2-BHNVJYJU-lfJQHw-7.js +1 -0
- package/web-shell/assets/{timeline-definition-PNZ67QCA-K9Mkex5A.js → timeline-definition-PNZ67QCA-CLO8b3FD.js} +1 -1
- package/web-shell/assets/{vennDiagram-CIIHVFJN-B2rVIw76.js → vennDiagram-CIIHVFJN-BNAAh0Mu.js} +1 -1
- package/web-shell/assets/{wardley-L42UT6IY-Z1w2JR4M.js → wardley-L42UT6IY-CUY7bLpN.js} +1 -1
- package/web-shell/assets/{wardleyDiagram-YWT4CUSO-CIX9aKXf.js → wardleyDiagram-YWT4CUSO-CSg_ORdW.js} +1 -1
- package/web-shell/assets/{xychartDiagram-2RQKCTM6-CI9DLIKB.js → xychartDiagram-2RQKCTM6-BjffV208.js} +1 -1
- package/web-shell/index.html +2 -2
- package/chunks/MaxSizedBox-INHRH72H.js +0 -86
- package/chunks/agent-VXDAN5JK.js +0 -82
- package/chunks/agent-headless-K4ZMMNBD.js +0 -76
- package/chunks/bridge-LGPZCFHO.js +0 -91
- package/chunks/channel-settings-store-CHCDRTPY.js +0 -89
- package/chunks/chunk-HGT6JR3U.js +0 -177
- package/chunks/chunk-JZA3JUDJ.js +0 -82
- package/chunks/chunk-SZRN75WQ.js +0 -29
- package/chunks/chunk-UGYMA4EI.js +0 -219
- package/chunks/chunk-VCBZUOSI.js +0 -8575
- package/chunks/contextCommand-QIZYHDR5.js +0 -81
- package/chunks/daemon-status-provider-OS5UWBHV.js +0 -90
- package/chunks/earlyInputCapture-WQT24RWD.js +0 -83
- package/chunks/environment-VZ7BRI4Q.js +0 -103
- package/chunks/errors-PCX25DVP.js +0 -89
- package/chunks/exitPlanMode-GHPUHBZJ.js +0 -423
- package/chunks/handleAutoUpdate-2CZQRJ66.js +0 -82
- package/chunks/i18n-XEQVMRKN.js +0 -98
- package/chunks/initializer-OVGZ4FLY.js +0 -87
- package/chunks/installationInfo-5UUQJI6Y.js +0 -81
- package/chunks/list-HODU6RXD.js +0 -90
- package/chunks/loadedSettingsAdapter-TYNLBALY.js +0 -84
- package/chunks/mcp-J3DFWX4A.js +0 -84
- package/chunks/nonInteractiveCli-F4GYSMHT.js +0 -144
- package/chunks/pidfile-4VNAR3EP.js +0 -87
- package/chunks/read-file-LZXUR4TO.js +0 -31
- package/chunks/resumeHistoryUtils-65OX3SGJ.js +0 -92
- package/chunks/ripGrep-2U2FRGMV.js +0 -74
- package/chunks/runtime-AXJWIEDU.js +0 -120
- package/chunks/serve-W2GC47CM.js +0 -90
- package/chunks/shell-45IPBDP5.js +0 -84
- package/chunks/spawnChannel-PVXQ5AGV.js +0 -83
- package/chunks/src-AY65BYR7.js +0 -3166
- package/chunks/standalone-update-ZMFNKAEY.js +0 -93
- package/chunks/task-create-N7WQSGYA.js +0 -25
- package/chunks/theme-manager-YYPZFBAH.js +0 -78
- package/chunks/total-session-admission-JXES723M.js +0 -85
- package/chunks/trustedFolders-HVI7IXUH.js +0 -94
- package/chunks/updateCheck-WUJGHWZZ.js +0 -93
- package/chunks/useAutoAcceptIndicator-CHSTZLZD.js +0 -94
- package/chunks/workspace-providers-status-GAKSF4LL.js +0 -87
- package/chunks/workspace-registry-A7NQUONG.js +0 -89
- package/chunks/workspace-service-STGVSO4N.js +0 -99
- package/chunks/workspace-skills-status-66AK3DUA.js +0 -86
- package/chunks/write-file-HUUCEG4P.js +0 -74
- package/web-shell/assets/channel-Bzdx6E8P.js +0 -1
- package/web-shell/assets/classDiagram-4FO5ZUOK-Cd6wbiuK.js +0 -1
- package/web-shell/assets/classDiagram-v2-Q7XG4LA2-Cd6wbiuK.js +0 -1
- package/web-shell/assets/index-B2bXx96W.js +0 -1249
- package/web-shell/assets/index-_8mKjx8q.css +0 -5
- package/web-shell/assets/stateDiagram-v2-BHNVJYJU-BjMdT6E_.js +0 -1
- package/chunks/{chunk-TARRHLLG.js → chunk-QUGAUQGJ.js} +25 -25
- package/chunks/{chunk-U7ZFW55U.js → chunk-VOQXFAY5.js} +977 -977
- /package/chunks/{chunk-LXXMOYPL.js → chunk-VXZBKKQR.js} +0 -0
|
@@ -3,16 +3,16 @@
|
|
|
3
3
|
import {
|
|
4
4
|
InvalidStreamError,
|
|
5
5
|
createOpenAIReasoningThoughtPart
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-2J3OJGTL.js";
|
|
7
7
|
import {
|
|
8
8
|
convertSchema,
|
|
9
9
|
relaxSchemaForFunctionCalling,
|
|
10
10
|
safeJsonParse,
|
|
11
11
|
setGenAiUsageProvenance
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-WK4TJUEA.js";
|
|
13
13
|
import {
|
|
14
14
|
setToolCallPreparations
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-GLCZKT5V.js";
|
|
16
16
|
import {
|
|
17
17
|
TOKEN_ESTIMATE_UNITS_PER_TOKEN,
|
|
18
18
|
estimateTextTokenUnits,
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
} from "./chunk-46UV252V.js";
|
|
22
22
|
import {
|
|
23
23
|
createDebugLogger
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-3RXUYQJI.js";
|
|
25
25
|
import {
|
|
26
26
|
FinishReason,
|
|
27
27
|
GenerateContentResponse
|
|
@@ -202,7 +202,9 @@ function convertGeminiToolParametersToOpenAI(parameters) {
|
|
|
202
202
|
}
|
|
203
203
|
const result = {};
|
|
204
204
|
for (const [key, value] of Object.entries(obj)) {
|
|
205
|
-
if (
|
|
205
|
+
if (typeof value === "object" && value !== null) {
|
|
206
|
+
result[key] = convertTypes(value);
|
|
207
|
+
} else if (key === "type" && typeof value === "string") {
|
|
206
208
|
const lowerValue = value.toLowerCase();
|
|
207
209
|
if (lowerValue === "integer") {
|
|
208
210
|
result[key] = "integer";
|
|
@@ -224,8 +226,6 @@ function convertGeminiToolParametersToOpenAI(parameters) {
|
|
|
224
226
|
} else {
|
|
225
227
|
result[key] = value;
|
|
226
228
|
}
|
|
227
|
-
} else if (typeof value === "object") {
|
|
228
|
-
result[key] = convertTypes(value);
|
|
229
229
|
} else {
|
|
230
230
|
result[key] = value;
|
|
231
231
|
}
|
|
@@ -109,38 +109,6 @@ function truncateToWidth(text, maxWidth) {
|
|
|
109
109
|
return `${result}${ellipsis}`;
|
|
110
110
|
}
|
|
111
111
|
__name(truncateToWidth, "truncateToWidth");
|
|
112
|
-
function wrapToVisualLines(text, width) {
|
|
113
|
-
if (width <= 0) {
|
|
114
|
-
return [""];
|
|
115
|
-
}
|
|
116
|
-
const visualLines = [];
|
|
117
|
-
for (const logicalLine of text.split("\n")) {
|
|
118
|
-
if (logicalLine === "") {
|
|
119
|
-
visualLines.push("");
|
|
120
|
-
continue;
|
|
121
|
-
}
|
|
122
|
-
let currentLine = "";
|
|
123
|
-
let currentWidth = 0;
|
|
124
|
-
for (const char of logicalLine) {
|
|
125
|
-
const charWidth = getCachedStringWidth(char);
|
|
126
|
-
if (currentWidth + charWidth > width && currentWidth > 0) {
|
|
127
|
-
visualLines.push(currentLine);
|
|
128
|
-
currentLine = "";
|
|
129
|
-
currentWidth = 0;
|
|
130
|
-
}
|
|
131
|
-
currentLine += char;
|
|
132
|
-
currentWidth += charWidth;
|
|
133
|
-
}
|
|
134
|
-
if (currentLine) {
|
|
135
|
-
visualLines.push(currentLine);
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
if (visualLines.length === 0) {
|
|
139
|
-
visualLines.push("");
|
|
140
|
-
}
|
|
141
|
-
return visualLines;
|
|
142
|
-
}
|
|
143
|
-
__name(wrapToVisualLines, "wrapToVisualLines");
|
|
144
112
|
var regex = ansiRegex();
|
|
145
113
|
var BARE_C0_CONTROL_CHARS_REGEX = /[\x00-\x08\x0b-\x1f\x7f-\x9f]/g;
|
|
146
114
|
var BIDI_OVERRIDE_CHARS_REGEX = /[\u200e\u200f\u202a-\u202e\u2066-\u2069]/g;
|
|
@@ -289,7 +257,6 @@ export {
|
|
|
289
257
|
stripUnsafeCharacters,
|
|
290
258
|
getCachedStringWidth,
|
|
291
259
|
truncateToWidth,
|
|
292
|
-
wrapToVisualLines,
|
|
293
260
|
sanitizeTerminalText,
|
|
294
261
|
escapeAnsiCtrlCodes,
|
|
295
262
|
sanitizeSensitiveText,
|
|
@@ -2,21 +2,41 @@
|
|
|
2
2
|
"use strict";
|
|
3
3
|
import {
|
|
4
4
|
HistoryReplayer
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-UOFFZNXV.js";
|
|
6
6
|
import {
|
|
7
7
|
ChannelDeliveryError,
|
|
8
8
|
MAX_CHANNEL_DELIVERY_TEXT_LENGTH
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-QONSRAEV.js";
|
|
10
10
|
import {
|
|
11
11
|
redactLogCredentials
|
|
12
12
|
} from "./chunk-M5GB774H.js";
|
|
13
13
|
import {
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
getUserSettingsPath,
|
|
15
|
+
loadSettings
|
|
16
|
+
} from "./chunk-LAPK3GLC.js";
|
|
17
|
+
import {
|
|
18
|
+
getSystemDefaultsPath,
|
|
19
|
+
getSystemSettingsPath
|
|
20
|
+
} from "./chunk-IDS7MSUP.js";
|
|
21
|
+
import {
|
|
22
|
+
findEnvFiles,
|
|
23
|
+
preResolveHomeEnvOverrides
|
|
24
|
+
} from "./chunk-AQEWCKX4.js";
|
|
25
|
+
import {
|
|
26
|
+
getResponseText,
|
|
27
|
+
ideContextStore
|
|
28
|
+
} from "./chunk-NGWYUZZO.js";
|
|
16
29
|
import {
|
|
17
30
|
MAX_CHANNEL_DELIVERY_NAME_LENGTH,
|
|
18
31
|
MAX_CHANNEL_DELIVERY_TARGET_ID_LENGTH
|
|
19
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-MOHAWIAW.js";
|
|
33
|
+
import {
|
|
34
|
+
parseGoalSnapshotV2
|
|
35
|
+
} from "./chunk-6FMJLI5M.js";
|
|
36
|
+
import {
|
|
37
|
+
Storage,
|
|
38
|
+
createDebugLogger
|
|
39
|
+
} from "./chunk-3RXUYQJI.js";
|
|
20
40
|
import {
|
|
21
41
|
init_esbuild_shims
|
|
22
42
|
} from "./chunk-5O2XNYP6.js";
|
|
@@ -24,7 +44,7 @@ import {
|
|
|
24
44
|
__name
|
|
25
45
|
} from "./chunk-J2S4EL5Y.js";
|
|
26
46
|
|
|
27
|
-
// packages/cli/src/
|
|
47
|
+
// packages/cli/src/runtime/workspace-remember-errors.ts
|
|
28
48
|
init_esbuild_shims();
|
|
29
49
|
var MAX_REMEMBER_ERROR_DETAILS_CHARS = 1e3;
|
|
30
50
|
var MAX_REMEMBER_ERROR_CAUSE_DEPTH = 50;
|
|
@@ -260,11 +280,11 @@ function workspaceMemoryFailureDiagnostics(err, onExtractionError) {
|
|
|
260
280
|
}
|
|
261
281
|
__name(workspaceMemoryFailureDiagnostics, "workspaceMemoryFailureDiagnostics");
|
|
262
282
|
|
|
263
|
-
// packages/cli/src/
|
|
283
|
+
// packages/cli/src/runtime/workspace-memory-remember-constants.ts
|
|
264
284
|
init_esbuild_shims();
|
|
265
285
|
var MAX_REMEMBER_CONTENT_BYTES = 64 * 1024;
|
|
266
286
|
|
|
267
|
-
// packages/cli/src/
|
|
287
|
+
// packages/cli/src/runtime/workspace-memory-summaries.ts
|
|
268
288
|
init_esbuild_shims();
|
|
269
289
|
function formatWorkspaceMemoryForgetSummary(removedEntryCount) {
|
|
270
290
|
return removedEntryCount > 0 ? `Forgot ${removedEntryCount} memory entr${removedEntryCount === 1 ? "y" : "ies"}.` : "No managed auto-memory entries matched.";
|
|
@@ -358,7 +378,7 @@ function restoreRedactedMcpServersSetting(value, existing) {
|
|
|
358
378
|
}
|
|
359
379
|
__name(restoreRedactedMcpServersSetting, "restoreRedactedMcpServersSetting");
|
|
360
380
|
|
|
361
|
-
// packages/cli/src/
|
|
381
|
+
// packages/cli/src/runtime/validate-server-name.ts
|
|
362
382
|
init_esbuild_shims();
|
|
363
383
|
var VALID_SERVER_NAME = /^[A-Za-z0-9_-]+$/;
|
|
364
384
|
var RESERVED_SERVER_NAMES = /* @__PURE__ */ new Set([
|
|
@@ -429,6 +449,121 @@ async function executeGeneration(config, requestId, prompt, signal, emit) {
|
|
|
429
449
|
}
|
|
430
450
|
__name(executeGeneration, "executeGeneration");
|
|
431
451
|
|
|
452
|
+
// packages/cli/src/config/settings-cache.ts
|
|
453
|
+
init_esbuild_shims();
|
|
454
|
+
import * as fs from "node:fs";
|
|
455
|
+
import * as os from "node:os";
|
|
456
|
+
import * as path from "node:path";
|
|
457
|
+
var MAX_CACHE_ENTRIES = 64;
|
|
458
|
+
var debugLogger = createDebugLogger("SETTINGS_CACHE");
|
|
459
|
+
var cache = /* @__PURE__ */ new Map();
|
|
460
|
+
function statSig(filePath) {
|
|
461
|
+
const st = fs.statSync(filePath, { throwIfNoEntry: false });
|
|
462
|
+
return st ? `${st.mtimeMs}:${st.size}:${st.ino}` : "missing";
|
|
463
|
+
}
|
|
464
|
+
__name(statSig, "statSig");
|
|
465
|
+
function realpathOr(p) {
|
|
466
|
+
try {
|
|
467
|
+
return fs.realpathSync(p);
|
|
468
|
+
} catch {
|
|
469
|
+
return path.resolve(p);
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
__name(realpathOr, "realpathOr");
|
|
473
|
+
function settingsFileSigs(workspaceDir) {
|
|
474
|
+
const filePaths = [
|
|
475
|
+
getSystemSettingsPath(),
|
|
476
|
+
getSystemDefaultsPath(),
|
|
477
|
+
getUserSettingsPath(),
|
|
478
|
+
new Storage(workspaceDir).getWorkspaceSettingsPath()
|
|
479
|
+
];
|
|
480
|
+
return filePaths.map((filePath) => ({ filePath, sig: statSig(filePath) }));
|
|
481
|
+
}
|
|
482
|
+
__name(settingsFileSigs, "settingsFileSigs");
|
|
483
|
+
function envFileSigs(settings, workspaceDir) {
|
|
484
|
+
return findEnvFiles(settings.merged, workspaceDir).map((filePath) => ({
|
|
485
|
+
filePath,
|
|
486
|
+
sig: statSig(filePath)
|
|
487
|
+
}));
|
|
488
|
+
}
|
|
489
|
+
__name(envFileSigs, "envFileSigs");
|
|
490
|
+
function sameFileSigs(a, b) {
|
|
491
|
+
if (a.length !== b.length) {
|
|
492
|
+
return false;
|
|
493
|
+
}
|
|
494
|
+
return a.every(
|
|
495
|
+
(sig, i) => sig.filePath === b[i].filePath && sig.sig === b[i].sig
|
|
496
|
+
);
|
|
497
|
+
}
|
|
498
|
+
__name(sameFileSigs, "sameFileSigs");
|
|
499
|
+
function isEntryFresh(key, entry) {
|
|
500
|
+
const fp = entry.fingerprint;
|
|
501
|
+
return ideContextStore.get()?.workspaceState?.isTrusted === fp.ideTrust && realpathOr(key) === fp.realCwd && // homeDir guards the corner where nothing else moves: QWEN_HOME set (so
|
|
502
|
+
// settings paths don't follow HOME), no .env files anywhere, and the new
|
|
503
|
+
// home equals the workspace dir — which flips workspaceSettingsActive.
|
|
504
|
+
realpathOr(os.homedir()) === fp.homeDir && sameFileSigs(settingsFileSigs(key), fp.settingsFiles) && sameFileSigs(envFileSigs(entry.settings, key), fp.envFiles);
|
|
505
|
+
}
|
|
506
|
+
__name(isEntryFresh, "isEntryFresh");
|
|
507
|
+
function loadSettingsCached(workspaceDir) {
|
|
508
|
+
preResolveHomeEnvOverrides();
|
|
509
|
+
const key = path.resolve(workspaceDir);
|
|
510
|
+
const entry = cache.get(key);
|
|
511
|
+
if (entry) {
|
|
512
|
+
let isFresh = false;
|
|
513
|
+
try {
|
|
514
|
+
isFresh = isEntryFresh(key, entry);
|
|
515
|
+
} catch (error) {
|
|
516
|
+
debugLogger.warn(
|
|
517
|
+
`fingerprint check failed for ${key}; reloading:`,
|
|
518
|
+
error
|
|
519
|
+
);
|
|
520
|
+
}
|
|
521
|
+
if (isFresh) {
|
|
522
|
+
cache.delete(key);
|
|
523
|
+
cache.set(key, entry);
|
|
524
|
+
debugLogger.debug(`hit ${key}`);
|
|
525
|
+
return entry.settings;
|
|
526
|
+
}
|
|
527
|
+
cache.delete(key);
|
|
528
|
+
}
|
|
529
|
+
debugLogger.debug(`miss ${key}`);
|
|
530
|
+
let preLoadSigs;
|
|
531
|
+
try {
|
|
532
|
+
preLoadSigs = settingsFileSigs(key);
|
|
533
|
+
} catch (error) {
|
|
534
|
+
debugLogger.warn(`pre-load signing failed for ${key}; not caching:`, error);
|
|
535
|
+
}
|
|
536
|
+
const settings = loadSettings(key);
|
|
537
|
+
if (preLoadSigs) {
|
|
538
|
+
try {
|
|
539
|
+
cache.set(key, {
|
|
540
|
+
settings,
|
|
541
|
+
fingerprint: {
|
|
542
|
+
settingsFiles: preLoadSigs,
|
|
543
|
+
// .env discovery needs the merged settings (trust), so it can only
|
|
544
|
+
// be signed after the load — see difference (2) in the module doc.
|
|
545
|
+
envFiles: envFileSigs(settings, key),
|
|
546
|
+
ideTrust: ideContextStore.get()?.workspaceState?.isTrusted,
|
|
547
|
+
realCwd: realpathOr(key),
|
|
548
|
+
homeDir: realpathOr(os.homedir())
|
|
549
|
+
}
|
|
550
|
+
});
|
|
551
|
+
if (cache.size > MAX_CACHE_ENTRIES) {
|
|
552
|
+
const oldest = cache.keys().next().value;
|
|
553
|
+
if (oldest !== void 0) {
|
|
554
|
+
cache.delete(oldest);
|
|
555
|
+
debugLogger.debug(`evicted LRU entry ${oldest}`);
|
|
556
|
+
}
|
|
557
|
+
}
|
|
558
|
+
} catch (error) {
|
|
559
|
+
cache.delete(key);
|
|
560
|
+
debugLogger.warn(`caching failed for ${key}; serving uncached:`, error);
|
|
561
|
+
}
|
|
562
|
+
}
|
|
563
|
+
return settings;
|
|
564
|
+
}
|
|
565
|
+
__name(loadSettingsCached, "loadSettingsCached");
|
|
566
|
+
|
|
432
567
|
// packages/cli/src/acp-integration/session/history-replay-page.ts
|
|
433
568
|
init_esbuild_shims();
|
|
434
569
|
function createReplayCumulativeUsage() {
|
|
@@ -498,7 +633,16 @@ function parseTranscriptReplayState(replay, logger) {
|
|
|
498
633
|
);
|
|
499
634
|
}
|
|
500
635
|
const cumulativeUsage = isCumulativeUsage(replay["cumulativeUsage"]) ? { ...replay["cumulativeUsage"] } : createReplayCumulativeUsage();
|
|
501
|
-
|
|
636
|
+
const rawGoalState = replay["goalState"];
|
|
637
|
+
const goalState = rawGoalState === void 0 ? void 0 : parseGoalSnapshotV2(rawGoalState);
|
|
638
|
+
if (logger && rawGoalState !== void 0 && !goalState) {
|
|
639
|
+
logger.warn("[transcript] replay state dropped a malformed Goal state");
|
|
640
|
+
}
|
|
641
|
+
return {
|
|
642
|
+
pendingToolCalls,
|
|
643
|
+
cumulativeUsage,
|
|
644
|
+
...goalState ? { goalState } : {}
|
|
645
|
+
};
|
|
502
646
|
}
|
|
503
647
|
__name(parseTranscriptReplayState, "parseTranscriptReplayState");
|
|
504
648
|
function replayContext(sessionId, updates, cumulativeUsage, config) {
|
|
@@ -580,7 +724,8 @@ async function replayTranscriptRecordPage({
|
|
|
580
724
|
const replayPageState = await replayer.replayPage(page.records, {
|
|
581
725
|
pendingToolCalls: page.direction === "backward" ? [] : state.pendingToolCalls,
|
|
582
726
|
finalizeDangling: page.direction === "backward" || !page.hasMore,
|
|
583
|
-
gaps: page.gaps
|
|
727
|
+
gaps: page.gaps,
|
|
728
|
+
...state.goalState ? { goalState: state.goalState } : {}
|
|
584
729
|
});
|
|
585
730
|
replayState = replayPageState.replay;
|
|
586
731
|
} catch (error) {
|
|
@@ -608,7 +753,7 @@ async function replayTranscriptRecordPage({
|
|
|
608
753
|
}
|
|
609
754
|
__name(replayTranscriptRecordPage, "replayTranscriptRecordPage");
|
|
610
755
|
|
|
611
|
-
// packages/cli/src/
|
|
756
|
+
// packages/cli/src/runtime/channel-delivery.ts
|
|
612
757
|
init_esbuild_shims();
|
|
613
758
|
var TRUNCATED_TEXT_SUFFIX = "\n\n[Channel delivery truncated because the result exceeded the delivery size limit.]";
|
|
614
759
|
function isBoundedString(value, maxLength) {
|
|
@@ -694,6 +839,7 @@ export {
|
|
|
694
839
|
GENERATION_MAX_PROMPT_BYTES,
|
|
695
840
|
GENERATION_TIMEOUT_MS,
|
|
696
841
|
executeGeneration,
|
|
842
|
+
loadSettingsCached,
|
|
697
843
|
parseChannelDelivery,
|
|
698
844
|
normalizeChannelDeliveryText,
|
|
699
845
|
normalizeChannelDelivery,
|
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
// Force strict mode and setup for ESM
|
|
2
2
|
"use strict";
|
|
3
|
+
import {
|
|
4
|
+
CHANNEL_LOOP_MCP_IPC_TIMEOUT_MS,
|
|
5
|
+
MAX_CHANNEL_LOOP_MCP_IN_FLIGHT,
|
|
6
|
+
createChannelLoopMcpRequest,
|
|
7
|
+
isChannelLoopMcpControlMessage,
|
|
8
|
+
isChannelLoopMcpResultMessage
|
|
9
|
+
} from "./chunk-FYJ7W2PI.js";
|
|
3
10
|
import {
|
|
4
11
|
CHANNEL_DAEMON_WORKER_SENTINEL,
|
|
5
12
|
CHANNEL_DELIVERY_IPC_TIMEOUT_MS,
|
|
@@ -23,23 +30,23 @@ import {
|
|
|
23
30
|
isChannelStartupReportType,
|
|
24
31
|
isChannelWebhookEnqueueErrorCode,
|
|
25
32
|
isChannelWebhookTaskResultMessage
|
|
26
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-QONSRAEV.js";
|
|
27
34
|
import {
|
|
28
35
|
createWorkerDiagnosticRedactor,
|
|
29
36
|
normalizeWorkerDiagnostic,
|
|
30
37
|
sanitizeWorkerDiagnostic
|
|
31
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-UHTJC7O3.js";
|
|
32
39
|
import {
|
|
33
40
|
channelSelectionNames
|
|
34
41
|
} from "./chunk-ALMR3E6Q.js";
|
|
35
|
-
import {
|
|
36
|
-
sanitizeLogText
|
|
37
|
-
} from "./chunk-ML52PL6O.js";
|
|
38
42
|
import {
|
|
39
43
|
CHANNEL_WORKER_KILL_GRACE_MS,
|
|
40
44
|
CHANNEL_WORKER_STARTUP_TIMEOUT_MS,
|
|
41
45
|
CHANNEL_WORKER_STOP_GRACE_MS
|
|
42
46
|
} from "./chunk-5HBA2Z7V.js";
|
|
47
|
+
import {
|
|
48
|
+
sanitizeLogText
|
|
49
|
+
} from "./chunk-GB3AB7TR.js";
|
|
43
50
|
import {
|
|
44
51
|
init_esbuild_shims
|
|
45
52
|
} from "./chunk-5O2XNYP6.js";
|
|
@@ -271,6 +278,8 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
271
278
|
let restartAttemptTimes = [];
|
|
272
279
|
const pendingWebhookTasks = /* @__PURE__ */ new Map();
|
|
273
280
|
const pendingChannelDeliveries = /* @__PURE__ */ new Map();
|
|
281
|
+
const pendingChannelLoopMcpMessages = /* @__PURE__ */ new Map();
|
|
282
|
+
let cleanupChannelLoopMcpRegistrations;
|
|
274
283
|
let restarting;
|
|
275
284
|
let disposed = false;
|
|
276
285
|
const snapshotCopy = /* @__PURE__ */ __name(() => ({
|
|
@@ -367,6 +376,28 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
367
376
|
}
|
|
368
377
|
return true;
|
|
369
378
|
}, "settleChannelDelivery");
|
|
379
|
+
const rejectPendingChannelLoopMcpMessages = /* @__PURE__ */ __name((message) => {
|
|
380
|
+
for (const pending of pendingChannelLoopMcpMessages.values()) {
|
|
381
|
+
clearTimeout(pending.timer);
|
|
382
|
+
pending.reject(new Error(message));
|
|
383
|
+
}
|
|
384
|
+
pendingChannelLoopMcpMessages.clear();
|
|
385
|
+
}, "rejectPendingChannelLoopMcpMessages");
|
|
386
|
+
const settleChannelLoopMcpMessage = /* @__PURE__ */ __name((message) => {
|
|
387
|
+
if (!isChannelLoopMcpResultMessage(message)) return false;
|
|
388
|
+
const pending = pendingChannelLoopMcpMessages.get(message.id);
|
|
389
|
+
if (!pending) return true;
|
|
390
|
+
pendingChannelLoopMcpMessages.delete(message.id);
|
|
391
|
+
clearTimeout(pending.timer);
|
|
392
|
+
if (message.ok) {
|
|
393
|
+
pending.resolve(message.payload ?? {});
|
|
394
|
+
} else {
|
|
395
|
+
pending.reject(
|
|
396
|
+
new Error(message.error ?? "Channel loop MCP request failed.")
|
|
397
|
+
);
|
|
398
|
+
}
|
|
399
|
+
return true;
|
|
400
|
+
}, "settleChannelLoopMcpMessage");
|
|
370
401
|
const pruneRestartAttempts = /* @__PURE__ */ __name((nowMs) => {
|
|
371
402
|
restartAttemptTimes = restartAttemptTimes.filter(
|
|
372
403
|
(attemptMs) => nowMs - attemptMs < restartPolicy.windowMs
|
|
@@ -529,6 +560,57 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
529
560
|
if (startedChild.pid !== void 0) {
|
|
530
561
|
snapshot = { ...snapshot, pid: startedChild.pid };
|
|
531
562
|
}
|
|
563
|
+
const channelLoopMcpOwnerId = `channel-worker:${randomUUID()}`;
|
|
564
|
+
const registeredChannelLoopMcpSessions = /* @__PURE__ */ new Set();
|
|
565
|
+
const activeChannelLoopMcpControls = /* @__PURE__ */ new Set();
|
|
566
|
+
const sendToStartedChild = /* @__PURE__ */ __name((message, callback) => {
|
|
567
|
+
if (child !== startedChild || !startedChild.send) {
|
|
568
|
+
throw new Error("Channel worker IPC is unavailable.");
|
|
569
|
+
}
|
|
570
|
+
return callback ? startedChild.send.call(startedChild, message, callback) : startedChild.send.call(startedChild, message);
|
|
571
|
+
}, "sendToStartedChild");
|
|
572
|
+
const sendChannelLoopMcpMessage = /* @__PURE__ */ __name((sessionId, payload) => {
|
|
573
|
+
if (pendingChannelLoopMcpMessages.size >= MAX_CHANNEL_LOOP_MCP_IN_FLIGHT) {
|
|
574
|
+
return Promise.reject(new Error("Channel loop MCP IPC queue is full."));
|
|
575
|
+
}
|
|
576
|
+
const message = createChannelLoopMcpRequest(sessionId, payload);
|
|
577
|
+
return new Promise((resolve, reject) => {
|
|
578
|
+
const timer = setTimeout(() => {
|
|
579
|
+
pendingChannelLoopMcpMessages.delete(message.id);
|
|
580
|
+
reject(new Error("Channel loop MCP IPC timed out."));
|
|
581
|
+
}, CHANNEL_LOOP_MCP_IPC_TIMEOUT_MS);
|
|
582
|
+
timer.unref();
|
|
583
|
+
pendingChannelLoopMcpMessages.set(message.id, {
|
|
584
|
+
resolve,
|
|
585
|
+
reject,
|
|
586
|
+
timer
|
|
587
|
+
});
|
|
588
|
+
try {
|
|
589
|
+
sendToStartedChild(message, (error) => {
|
|
590
|
+
if (!error) return;
|
|
591
|
+
const pending = pendingChannelLoopMcpMessages.get(message.id);
|
|
592
|
+
if (!pending) return;
|
|
593
|
+
pendingChannelLoopMcpMessages.delete(message.id);
|
|
594
|
+
clearTimeout(pending.timer);
|
|
595
|
+
pending.reject(new Error("Channel loop MCP IPC send failed."));
|
|
596
|
+
});
|
|
597
|
+
} catch {
|
|
598
|
+
const pending = pendingChannelLoopMcpMessages.get(message.id);
|
|
599
|
+
if (!pending) return;
|
|
600
|
+
pendingChannelLoopMcpMessages.delete(message.id);
|
|
601
|
+
clearTimeout(pending.timer);
|
|
602
|
+
pending.reject(new Error("Channel loop MCP IPC send failed."));
|
|
603
|
+
}
|
|
604
|
+
});
|
|
605
|
+
}, "sendChannelLoopMcpMessage");
|
|
606
|
+
const cleanupLaunchChannelLoopMcpRegistrations = /* @__PURE__ */ __name(() => {
|
|
607
|
+
for (const sessionId of registeredChannelLoopMcpSessions) {
|
|
608
|
+
void opts.unregisterChannelLoopMcp?.(sessionId, channelLoopMcpOwnerId).catch(() => {
|
|
609
|
+
});
|
|
610
|
+
}
|
|
611
|
+
registeredChannelLoopMcpSessions.clear();
|
|
612
|
+
}, "cleanupLaunchChannelLoopMcpRegistrations");
|
|
613
|
+
cleanupChannelLoopMcpRegistrations = cleanupLaunchChannelLoopMcpRegistrations;
|
|
532
614
|
await new Promise((resolve, reject) => {
|
|
533
615
|
let settled = false;
|
|
534
616
|
let ready = false;
|
|
@@ -725,6 +807,61 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
725
807
|
};
|
|
726
808
|
armStaleHeartbeatTimer(startedChild);
|
|
727
809
|
}, "handleHeartbeat");
|
|
810
|
+
const sendChannelLoopMcpControlResult = /* @__PURE__ */ __name((id, result) => {
|
|
811
|
+
try {
|
|
812
|
+
sendToStartedChild({
|
|
813
|
+
type: "channel_loop_mcp_control_result",
|
|
814
|
+
id,
|
|
815
|
+
...result
|
|
816
|
+
});
|
|
817
|
+
} catch {
|
|
818
|
+
}
|
|
819
|
+
}, "sendChannelLoopMcpControlResult");
|
|
820
|
+
const handleChannelLoopMcpControl = /* @__PURE__ */ __name((message) => {
|
|
821
|
+
if (activeChannelLoopMcpControls.size >= MAX_CHANNEL_LOOP_MCP_IN_FLIGHT) {
|
|
822
|
+
sendChannelLoopMcpControlResult(message.id, {
|
|
823
|
+
ok: false,
|
|
824
|
+
error: "Channel loop MCP IPC queue is full."
|
|
825
|
+
});
|
|
826
|
+
return;
|
|
827
|
+
}
|
|
828
|
+
activeChannelLoopMcpControls.add(message.id);
|
|
829
|
+
const operation = message.type === "channel_loop_mcp_register" ? opts.registerChannelLoopMcp?.({
|
|
830
|
+
sessionId: message.sessionId,
|
|
831
|
+
ownerId: channelLoopMcpOwnerId,
|
|
832
|
+
sendMessage: /* @__PURE__ */ __name((payload) => sendChannelLoopMcpMessage(message.sessionId, payload), "sendMessage")
|
|
833
|
+
}).then(async () => {
|
|
834
|
+
if (child !== startedChild) {
|
|
835
|
+
await opts.unregisterChannelLoopMcp?.(
|
|
836
|
+
message.sessionId,
|
|
837
|
+
channelLoopMcpOwnerId
|
|
838
|
+
);
|
|
839
|
+
throw new Error("Channel worker exited during MCP setup.");
|
|
840
|
+
}
|
|
841
|
+
registeredChannelLoopMcpSessions.add(message.sessionId);
|
|
842
|
+
}) ?? Promise.reject(
|
|
843
|
+
new Error("Channel loop MCP registration is unavailable.")
|
|
844
|
+
) : opts.unregisterChannelLoopMcp?.(
|
|
845
|
+
message.sessionId,
|
|
846
|
+
channelLoopMcpOwnerId
|
|
847
|
+
).then(() => {
|
|
848
|
+
registeredChannelLoopMcpSessions.delete(message.sessionId);
|
|
849
|
+
}) ?? Promise.resolve();
|
|
850
|
+
void operation.then(() => {
|
|
851
|
+
sendChannelLoopMcpControlResult(message.id, { ok: true });
|
|
852
|
+
}).catch((error) => {
|
|
853
|
+
sendChannelLoopMcpControlResult(message.id, {
|
|
854
|
+
ok: false,
|
|
855
|
+
error: sanitizeWorkerDiagnostic(
|
|
856
|
+
error instanceof Error ? error.message : String(error),
|
|
857
|
+
512,
|
|
858
|
+
redaction
|
|
859
|
+
) || "Channel loop MCP operation failed."
|
|
860
|
+
});
|
|
861
|
+
}).finally(() => {
|
|
862
|
+
activeChannelLoopMcpControls.delete(message.id);
|
|
863
|
+
});
|
|
864
|
+
}, "handleChannelLoopMcpControl");
|
|
728
865
|
function handleMessage(message) {
|
|
729
866
|
if (child !== startedChild) return;
|
|
730
867
|
if (settleChannelDelivery(message)) {
|
|
@@ -733,6 +870,13 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
733
870
|
if (settleWebhookTask(message)) {
|
|
734
871
|
return;
|
|
735
872
|
}
|
|
873
|
+
if (settleChannelLoopMcpMessage(message)) {
|
|
874
|
+
return;
|
|
875
|
+
}
|
|
876
|
+
if (isChannelLoopMcpControlMessage(message)) {
|
|
877
|
+
handleChannelLoopMcpControl(message);
|
|
878
|
+
return;
|
|
879
|
+
}
|
|
736
880
|
if (!ready && isChannelStartupReportType(message)) {
|
|
737
881
|
handleStartupReport(message);
|
|
738
882
|
} else if (!ready && isReadyMessage(message)) {
|
|
@@ -762,6 +906,11 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
762
906
|
"channel_worker_unavailable",
|
|
763
907
|
"Channel worker exited."
|
|
764
908
|
);
|
|
909
|
+
rejectPendingChannelLoopMcpMessages("Channel worker exited.");
|
|
910
|
+
cleanupLaunchChannelLoopMcpRegistrations();
|
|
911
|
+
if (cleanupChannelLoopMcpRegistrations === cleanupLaunchChannelLoopMcpRegistrations) {
|
|
912
|
+
cleanupChannelLoopMcpRegistrations = void 0;
|
|
913
|
+
}
|
|
765
914
|
child = void 0;
|
|
766
915
|
if ((ready || kind === "restart") && !stopping) {
|
|
767
916
|
scheduleRestart();
|
|
@@ -841,6 +990,7 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
841
990
|
"channel_worker_unavailable",
|
|
842
991
|
"Channel worker stopped."
|
|
843
992
|
);
|
|
993
|
+
rejectPendingChannelLoopMcpMessages("Channel worker stopped.");
|
|
844
994
|
if (!child || snapshot.state === "exited" || snapshot.state === "failed" && hasObservedExit(snapshot) || snapshot.state === "stopped") {
|
|
845
995
|
child = void 0;
|
|
846
996
|
snapshot = { ...snapshot, state: "stopped" };
|
|
@@ -889,6 +1039,9 @@ function createChannelWorkerSupervisor(opts) {
|
|
|
889
1039
|
"channel_worker_unavailable",
|
|
890
1040
|
"Channel worker stopped."
|
|
891
1041
|
);
|
|
1042
|
+
rejectPendingChannelLoopMcpMessages("Channel worker stopped.");
|
|
1043
|
+
cleanupChannelLoopMcpRegistrations?.();
|
|
1044
|
+
cleanupChannelLoopMcpRegistrations = void 0;
|
|
892
1045
|
if (!child || snapshot.state === "exited" || snapshot.state === "failed" && hasObservedExit(snapshot) || snapshot.state === "stopped") {
|
|
893
1046
|
clearRestartTimer();
|
|
894
1047
|
clearStaleHeartbeatTimer();
|
|
@@ -3513,7 +3513,6 @@ var require_streams = __commonJS({
|
|
|
3513
3513
|
// node_modules/iconv-lite/lib/index.js
|
|
3514
3514
|
var require_lib = __commonJS({
|
|
3515
3515
|
"node_modules/iconv-lite/lib/index.js"(exports, module) {
|
|
3516
|
-
"use strict";
|
|
3517
3516
|
init_esbuild_shims();
|
|
3518
3517
|
var Buffer = require_safer().Buffer;
|
|
3519
3518
|
var bomHandling = require_bom_handling();
|