opencode-swarm 7.179.0 → 7.180.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/.opencode/skills/execute/SKILL.md +9 -8
- package/.opencode/skills/running-tests/SKILL.md +41 -36
- package/.opencode/skills/writing-tests/SKILL.md +11 -4
- package/binaries/win32-arm64/swarm-sandbox-runner.exe +0 -0
- package/binaries/win32-x64/swarm-sandbox-runner.exe +0 -0
- package/dist/agents/explorer.d.ts +1 -1
- package/dist/background/pr-event-subscribers.d.ts +2 -0
- package/dist/background/pr-feedback-event-queue.d.ts +7 -0
- package/dist/background/pr-feedback-loop.d.ts +162 -0
- package/dist/cli/{coder-settlement-7pt3a0y0.js → coder-settlement-34z9xgnx.js} +13 -13
- package/dist/cli/{config-doctor-82w4bp4b.js → config-doctor-tkfrwztz.js} +2 -2
- package/dist/cli/{core-9rqzs794.js → core-z9ybzpvr.js} +4 -5
- package/dist/cli/{curation-policy-c7mdsf7m.js → curation-policy-gwzmjmt7.js} +6 -5
- package/dist/cli/{curator-drift-d93pwt8h.js → curator-drift-3bbn011w.js} +22 -12
- package/dist/cli/curator-llm-factory-e162g7xp.js +74 -0
- package/dist/cli/{curator-m8act07j.js → curator-zv4qs07j.js} +46 -44
- package/dist/cli/{dispatch-3rwdxpp2.js → dispatch-p5zjg5e6.js} +1 -1
- package/dist/cli/{evidence-summary-service-a99bgje1.js → evidence-summary-service-wrfth5tr.js} +22 -20
- package/dist/cli/{explorer-z0cf5cz0.js → explorer-m50sfrp7.js} +1 -1
- package/dist/cli/{gate-evidence-yssmxba5.js → gate-evidence-adqbxnm7.js} +8 -8
- package/dist/cli/guardrail-explain-dn96802k.js +75 -0
- package/dist/cli/{guardrail-log-j2wtq7p2.js → guardrail-log-rcza6v3y.js} +6 -6
- package/dist/cli/{guardrail-reset-07byr7nr.js → guardrail-reset-fjn42e0n.js} +46 -44
- package/dist/cli/hive-promoter-hgqqn7qw.js +89 -0
- package/dist/cli/{index-7zmbtxw1.js → index-06crt1ej.js} +2 -2
- package/dist/cli/{index-wrt875kh.js → index-0725jpp7.js} +1 -1
- package/dist/cli/{index-f2v90gfc.js → index-0v1rtanv.js} +24 -165
- package/dist/cli/{index-0bc8jdnv.js → index-1hzqyx13.js} +9 -1
- package/dist/cli/{index-80q47hpw.js → index-1p8fk9jb.js} +2 -2
- package/dist/cli/{index-1rwyfvq2.js → index-2h0qng38.js} +3 -3
- package/dist/cli/{index-amf88k1e.js → index-3jap3516.js} +1 -1
- package/dist/cli/{index-8815e95e.js → index-5gmn0a3j.js} +8 -8
- package/dist/cli/{index-yagqxt2p.js → index-5m378633.js} +4 -4
- package/dist/cli/{index-0h3cr7pn.js → index-5yc5n4ae.js} +1 -1
- package/dist/cli/{index-pxtye2ng.js → index-7pj0x345.js} +50 -48
- package/dist/cli/{index-etmwjgre.js → index-7w6dnpvc.js} +46 -44
- package/dist/cli/{index-6tnkvqr9.js → index-8b1f2t5q.js} +8 -10
- package/dist/cli/{index-cvg402ha.js → index-91dhg3wr.js} +2 -2
- package/dist/cli/{index-3pzwsesm.js → index-92m05mew.js} +2 -2
- package/dist/cli/{index-6r92fw88.js → index-93vk5s7v.js} +8 -8
- package/dist/cli/{index-ne9zamcs.js → index-989v83pb.js} +1 -1
- package/dist/cli/{index-g6nyk713.js → index-aspxz5r5.js} +1 -1
- package/dist/cli/index-b9z9gvx0.js +339 -0
- package/dist/cli/{index-2b0ktpbf.js → index-bdpgfep1.js} +5 -5
- package/dist/cli/{index-nzekzzs2.js → index-bv4b8tpa.js} +5 -5
- package/dist/cli/{index-n1tcj1q7.js → index-bx70zs8d.js} +187 -47
- package/dist/cli/{index-kmhnkn6t.js → index-caj76d0f.js} +6 -8
- package/dist/cli/{index-549wxbe1.js → index-cjapb4hy.js} +1 -1
- package/dist/cli/{index-3hne91yd.js → index-cxgr6ad5.js} +13 -15
- package/dist/cli/{index-kanxpgf8.js → index-dcttq1mn.js} +2 -2
- package/dist/cli/{index-twtez316.js → index-defq2crz.js} +13 -3
- package/dist/cli/{index-d66zb40k.js → index-dnbqmay5.js} +3054 -1454
- package/dist/cli/index-ejhxgyvm.js +147 -0
- package/dist/cli/{index-hwcra3y9.js → index-ekgc71m1.js} +10 -10
- package/dist/cli/{index-s4bkey0q.js → index-gc6h1fmf.js} +4 -4
- package/dist/cli/index-gx2vp8gx.js +100 -0
- package/dist/cli/{index-zgvzbz48.js → index-hamqvzqn.js} +69 -13
- package/dist/cli/{index-h59vsbch.js → index-htrb9ec3.js} +1 -1
- package/dist/cli/{index-yfpswnjt.js → index-jmrsfhwq.js} +3 -3
- package/dist/cli/{index-9p1pqykb.js → index-jrfv2am8.js} +7 -7
- package/dist/cli/{index-pskba939.js → index-jscqefqm.js} +1 -1
- package/dist/cli/{index-wvpsm8ja.js → index-kp654qcw.js} +32 -17
- package/dist/cli/{index-tmy46dtd.js → index-mhrn7hbb.js} +8 -7
- package/dist/cli/{index-h4nh6s8b.js → index-nhxykfyy.js} +1 -1
- package/dist/cli/{index-ndwbb3xm.js → index-pnt98k7z.js} +7 -7
- package/dist/cli/{index-1c1dbwze.js → index-rdec0y3z.js} +1 -1
- package/dist/cli/{index-qxk5qkfh.js → index-ret97f1t.js} +5 -5
- package/dist/cli/{index-sv4y1cma.js → index-v1sc1gxv.js} +6 -6
- package/dist/cli/{index-a11ztzs5.js → index-vmthakz0.js} +1 -1
- package/dist/cli/{index-09wm3963.js → index-x6kjbjya.js} +9 -7
- package/dist/cli/{index-1sz02k85.js → index-zptq8mp1.js} +4 -103
- package/dist/cli/{index-34bwqcea.js → index-zvxy0mev.js} +1 -1
- package/dist/cli/{index-zz7gzw57.js → index-zxdawwc7.js} +88 -4
- package/dist/cli/index.js +47 -45
- package/dist/cli/{knowledge-escalator-yx97q9c1.js → knowledge-escalator-x8vcmb6k.js} +16 -15
- package/dist/cli/{knowledge-events-p269fyvv.js → knowledge-events-naf9kyyc.js} +14 -13
- package/dist/cli/{knowledge-link-gfz47ves.js → knowledge-link-g0q25hqv.js} +5 -4
- package/dist/cli/{knowledge-store-36zemyqa.js → knowledge-store-dnv0ph42.js} +6 -5
- package/dist/cli/{knowledge-validator-rd20yq41.js → knowledge-validator-a1rfzkmv.js} +8 -7
- package/dist/cli/{mcp-sg9zrkz2.js → mcp-hnb0m05a.js} +1 -1
- package/dist/cli/{pending-delegations-8p2gf4kt.js → pending-delegations-05p6cmbh.js} +13 -12
- package/dist/cli/{pr-subscriptions-4dj9r71h.js → pr-subscriptions-a2djfzyx.js} +13 -12
- package/dist/cli/{pr-workflow-gate-8dgz5z1h.js → pr-workflow-gate-wkmx8nr6.js} +48 -44
- package/dist/cli/{runner-16b691ba.js → runner-hkbds12j.js} +6 -5
- package/dist/cli/{scan-cursor-nx0jv9ya.js → scan-cursor-4khfn5pm.js} +8 -8
- package/dist/cli/{schema-q6gsrxwz.js → schema-a5zb02h8.js} +3 -1
- package/dist/cli/{scope-persistence-1k4xsyh7.js → scope-persistence-nsw324ce.js} +18 -17
- package/dist/cli/{server-shhxq34t.js → server-exj4wt8j.js} +54 -52
- package/dist/cli/{skill-generator-6j7tq2tb.js → skill-generator-r2cdtx7b.js} +18 -17
- package/dist/cli/{snapshot-coordination-init-h8n8w1cm.js → snapshot-coordination-init-sad6q0a2.js} +46 -44
- package/dist/cli/speckit-checkoff-46g9sqak.js +31 -0
- package/dist/cli/{workspace-snapshot-rfnn80dg.js → workspace-snapshot-4m2ex1ey.js} +4 -5
- package/dist/cli/{worktree-collision-ownership-97jzh4ra.js → worktree-collision-ownership-4znkfq1t.js} +16 -16
- package/dist/cli/{worktree-isolation-g4w74ccb.js → worktree-isolation-mv9ee00v.js} +46 -44
- package/dist/commands/pr-feedback-loop.d.ts +1 -0
- package/dist/commands/registry.d.ts +10 -2
- package/dist/config/schema.d.ts +27 -0
- package/dist/hooks/delegation-tracker.d.ts +6 -1
- package/dist/hooks/pr-workflow-gate.d.ts +1 -1
- package/dist/index.js +639 -606
- package/dist/lang/backends/go.d.ts +2 -0
- package/dist/mutation/engine.d.ts +1 -0
- package/dist/sdd/effective-spec.d.ts +35 -22
- package/dist/sdd/speckit-checkoff.d.ts +113 -0
- package/dist/session/hydration-ownership.d.ts +83 -0
- package/dist/session/snapshot-coordination-init.d.ts +2 -1
- package/dist/session/snapshot-reader.d.ts +25 -7
- package/dist/state.d.ts +32 -2
- package/dist/test-impact/analyzer.d.ts +46 -4
- package/dist/test-impact/constants.d.ts +4 -0
- package/dist/tools/mutation-test.d.ts +11 -5
- package/dist/tools/test-runner.d.ts +34 -6
- package/opencode-swarm.schema.json +40 -0
- package/package.json +1 -1
- package/dist/cli/curator-llm-factory-cbm1ny30.js +0 -72
- package/dist/cli/guardrail-explain-ffwmhf7s.js +0 -73
- package/dist/cli/hive-promoter-ewrz7vh1.js +0 -87
- package/dist/cli/index-4ddpvd5c.js +0 -94
|
@@ -11,16 +11,16 @@ import {
|
|
|
11
11
|
} from "./index-ae75rja9.js";
|
|
12
12
|
import {
|
|
13
13
|
resolveKnowledgeStoreDir
|
|
14
|
-
} from "./index-
|
|
14
|
+
} from "./index-zvxy0mev.js";
|
|
15
15
|
import {
|
|
16
16
|
atomicWriteFile
|
|
17
|
-
} from "./index-
|
|
17
|
+
} from "./index-0v1rtanv.js";
|
|
18
18
|
import {
|
|
19
19
|
require_proper_lockfile
|
|
20
20
|
} from "./index-7g4c7s5r.js";
|
|
21
21
|
import {
|
|
22
22
|
readCachedParsedFile
|
|
23
|
-
} from "./index-
|
|
23
|
+
} from "./index-989v83pb.js";
|
|
24
24
|
import {
|
|
25
25
|
init_knowledge_types,
|
|
26
26
|
isActiveStatus
|
|
@@ -739,7 +739,7 @@ async function applyConfidenceFloorAction(directory, touched, options) {
|
|
|
739
739
|
const {
|
|
740
740
|
readAuthoritativeKnowledgeCounterRollups,
|
|
741
741
|
effectiveRetrievalOutcomes
|
|
742
|
-
} = await import("./knowledge-events-
|
|
742
|
+
} = await import("./knowledge-events-naf9kyyc.js");
|
|
743
743
|
const rollups = await readAuthoritativeKnowledgeCounterRollups(directory);
|
|
744
744
|
const flagIds = new Set;
|
|
745
745
|
for (const e of atFloor) {
|
|
@@ -806,11 +806,11 @@ async function applyConfidenceFloorAction(directory, touched, options) {
|
|
|
806
806
|
});
|
|
807
807
|
}
|
|
808
808
|
if (action === "quarantine" && toQuarantine.length > 0) {
|
|
809
|
-
const { quarantineEntry } = await import("./knowledge-validator-
|
|
810
|
-
const { KnowledgeConfigSchema } = await import("./schema-
|
|
809
|
+
const { quarantineEntry } = await import("./knowledge-validator-a1rfzkmv.js");
|
|
810
|
+
const { KnowledgeConfigSchema } = await import("./schema-a5zb02h8.js");
|
|
811
811
|
let config;
|
|
812
812
|
try {
|
|
813
|
-
const { loadPluginConfigWithMeta } = await import("./index-
|
|
813
|
+
const { loadPluginConfigWithMeta } = await import("./index-mhrn7hbb.js");
|
|
814
814
|
const { config: loadedConfig } = loadPluginConfigWithMeta(directory);
|
|
815
815
|
config = KnowledgeConfigSchema.parse(loadedConfig.knowledge ?? {});
|
|
816
816
|
} catch {
|
|
@@ -38,7 +38,7 @@ INPUT: [focus areas/paths]
|
|
|
38
38
|
|
|
39
39
|
ACTIONS:
|
|
40
40
|
- FIRST call \`repo_map action="ask"\` with your mission question, and \`action="context_pack"\` (with include_source: true) for your target symbols; use the hits to decide what to read
|
|
41
|
-
-
|
|
41
|
+
- For symbol discovery call \`repo_map action="symbol_search" symbol="<name>" top_n=25\`, resolve a selected hit with \`repo_map action="symbol_context" file="<path>" symbol="<name>" include_source=true top_n=25\`, and use \`repo_map action="graph_explain" file="<path>" symbol="<name>" line=<line> top_n=20\` when the graph relationship needs explanation. Verify every graph claim and provenance against source; if the graph is missing, stale, unsupported, or fails, fall back to tree/glob/grep, direct reads, and search.
|
|
42
42
|
- Graph output is orientation \u2014 read the located files before reporting on them
|
|
43
43
|
- Fall back to tree/glob/grep only where the graph has no coverage (\`stale: true\`, missing files, or non-code assets)
|
|
44
44
|
- Read key files (README, configs, entry points)
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
queryHistoricalOutcomes,
|
|
4
4
|
readKnowledgeEvents,
|
|
5
5
|
recordKnowledgeEvent
|
|
6
|
-
} from "./index-
|
|
6
|
+
} from "./index-ekgc71m1.js";
|
|
7
7
|
import {
|
|
8
8
|
jaccardBigram,
|
|
9
9
|
readKnowledge,
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
resolveSwarmKnowledgePath,
|
|
12
12
|
transactKnowledge,
|
|
13
13
|
wordBigrams
|
|
14
|
-
} from "./index-
|
|
14
|
+
} from "./index-pnt98k7z.js";
|
|
15
15
|
import {
|
|
16
16
|
init_knowledge_types,
|
|
17
17
|
isActiveStatus
|
|
@@ -224,11 +224,11 @@ async function maybeQuarantineOnContradiction(directory, entryId, threshold, win
|
|
|
224
224
|
alreadyInactive: true
|
|
225
225
|
};
|
|
226
226
|
}
|
|
227
|
-
const { quarantineEntry } = await import("./knowledge-validator-
|
|
227
|
+
const { quarantineEntry } = await import("./knowledge-validator-a1rfzkmv.js");
|
|
228
228
|
let policyConfig;
|
|
229
229
|
try {
|
|
230
|
-
const { KnowledgeConfigSchema } = await import("./schema-
|
|
231
|
-
const { loadPluginConfigWithMeta } = await import("./index-
|
|
230
|
+
const { KnowledgeConfigSchema } = await import("./schema-a5zb02h8.js");
|
|
231
|
+
const { loadPluginConfigWithMeta } = await import("./index-mhrn7hbb.js");
|
|
232
232
|
const { config: loadedConfig } = loadPluginConfigWithMeta(directory);
|
|
233
233
|
policyConfig = KnowledgeConfigSchema.parse(loadedConfig.knowledge ?? {});
|
|
234
234
|
} catch {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
validateSwarmPath
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-gc6h1fmf.js";
|
|
5
5
|
import {
|
|
6
6
|
bunWrite
|
|
7
7
|
} from "./index-2s7dvzff.js";
|
|
@@ -18,18 +18,18 @@ import {
|
|
|
18
18
|
releaseCoordinationLease,
|
|
19
19
|
transitionCoordinationState,
|
|
20
20
|
withCoordinationTransaction
|
|
21
|
-
} from "./index-
|
|
21
|
+
} from "./index-vmthakz0.js";
|
|
22
22
|
import {
|
|
23
23
|
getProjectDb,
|
|
24
24
|
projectDbExists
|
|
25
|
-
} from "./index-
|
|
25
|
+
} from "./index-bv4b8tpa.js";
|
|
26
26
|
import {
|
|
27
27
|
observeDelegationLedgerPressure
|
|
28
|
-
} from "./index-
|
|
28
|
+
} from "./index-jmrsfhwq.js";
|
|
29
29
|
import {
|
|
30
30
|
EvidenceLockTimeoutError,
|
|
31
31
|
withEvidenceLock
|
|
32
|
-
} from "./index-
|
|
32
|
+
} from "./index-0v1rtanv.js";
|
|
33
33
|
import {
|
|
34
34
|
telemetry
|
|
35
35
|
} from "./index-qt0793qm.js";
|
|
@@ -4660,7 +4660,7 @@ async function reconcileLegacyCoderSettlements(directory, maxRecords, onReconcil
|
|
|
4660
4660
|
const candidates = readDelegations(directory).filter((record) => record.normalizedAgent === "coder" && Boolean(record.legacyCoderSettlementTransfer) && Boolean(record.terminalResult)).slice(0, maxRecords);
|
|
4661
4661
|
if (candidates.length === 0)
|
|
4662
4662
|
return 0;
|
|
4663
|
-
const { transferCoderSettlementToBackground } = await import("./coder-settlement-
|
|
4663
|
+
const { transferCoderSettlementToBackground } = await import("./coder-settlement-34z9xgnx.js");
|
|
4664
4664
|
let transferred = 0;
|
|
4665
4665
|
for (const record of candidates) {
|
|
4666
4666
|
try {
|
|
@@ -2,17 +2,17 @@
|
|
|
2
2
|
import {
|
|
3
3
|
derivePlanId,
|
|
4
4
|
derivePlanIdentityHash
|
|
5
|
-
} from "./index-
|
|
5
|
+
} from "./index-vmthakz0.js";
|
|
6
6
|
import {
|
|
7
7
|
getProjectDb,
|
|
8
8
|
projectDbExists,
|
|
9
9
|
withImmediateTransaction,
|
|
10
10
|
withProjectDbReadOnly
|
|
11
|
-
} from "./index-
|
|
11
|
+
} from "./index-bv4b8tpa.js";
|
|
12
12
|
import {
|
|
13
13
|
assertProjectRoot,
|
|
14
14
|
withEvidenceLock
|
|
15
|
-
} from "./index-
|
|
15
|
+
} from "./index-0v1rtanv.js";
|
|
16
16
|
import {
|
|
17
17
|
emit
|
|
18
18
|
} from "./index-qt0793qm.js";
|
|
@@ -20,14 +20,16 @@ import {
|
|
|
20
20
|
ExecutionProfileSchema,
|
|
21
21
|
PlanSchema,
|
|
22
22
|
TaskStatusSchema,
|
|
23
|
-
init_loader,
|
|
24
|
-
loadPluginConfig,
|
|
25
23
|
normalizeCurrentPhaseInPlace
|
|
26
|
-
} from "./index-
|
|
24
|
+
} from "./index-gx2vp8gx.js";
|
|
25
|
+
import {
|
|
26
|
+
init_loader,
|
|
27
|
+
loadPluginConfig
|
|
28
|
+
} from "./index-zptq8mp1.js";
|
|
27
29
|
import {
|
|
28
30
|
init_package,
|
|
29
31
|
package_default
|
|
30
|
-
} from "./index-
|
|
32
|
+
} from "./index-defq2crz.js";
|
|
31
33
|
import {
|
|
32
34
|
criticalWarn,
|
|
33
35
|
init_logger,
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
GIT_BINARY_ENV_VAR,
|
|
4
|
-
init_git_executable
|
|
5
|
-
} from "./index-zz7gzw57.js";
|
|
6
|
-
import {
|
|
7
4
|
advisoryWarn,
|
|
5
|
+
init_git_executable,
|
|
8
6
|
init_warning_buffer
|
|
9
|
-
} from "./index-
|
|
7
|
+
} from "./index-zxdawwc7.js";
|
|
10
8
|
import {
|
|
11
9
|
ExternalSkillsConfigSchema,
|
|
12
10
|
GATE_CONFIG_KNOWN_SECTION_KEYS,
|
|
@@ -14,11 +12,7 @@ import {
|
|
|
14
12
|
PluginConfigSchema,
|
|
15
13
|
init_schema,
|
|
16
14
|
resolveExternalSkillsConfig
|
|
17
|
-
} from "./index-
|
|
18
|
-
import {
|
|
19
|
-
exports_external,
|
|
20
|
-
init_zod
|
|
21
|
-
} from "./index-gknz3bv1.js";
|
|
15
|
+
} from "./index-defq2crz.js";
|
|
22
16
|
import {
|
|
23
17
|
DangerousMergeKeyError,
|
|
24
18
|
MAX_MERGE_DEPTH,
|
|
@@ -808,97 +802,4 @@ var init_loader = __esm(() => {
|
|
|
808
802
|
};
|
|
809
803
|
});
|
|
810
804
|
|
|
811
|
-
|
|
812
|
-
init_zod();
|
|
813
|
-
var ExecutionProfileSchema = exports_external.object({
|
|
814
|
-
parallelization_enabled: exports_external.boolean().default(false),
|
|
815
|
-
max_concurrent_tasks: exports_external.number().int().min(1).max(64).default(10),
|
|
816
|
-
council_parallel: exports_external.boolean().default(true),
|
|
817
|
-
locked: exports_external.boolean().default(false),
|
|
818
|
-
auto_proceed: exports_external.boolean().default(false),
|
|
819
|
-
commit_after_each_completed_task: exports_external.boolean().default(false),
|
|
820
|
-
planning_profile: exports_external.enum(["balanced", "strict"]).optional()
|
|
821
|
-
});
|
|
822
|
-
var TaskStatusSchema = exports_external.enum([
|
|
823
|
-
"pending",
|
|
824
|
-
"in_progress",
|
|
825
|
-
"completed",
|
|
826
|
-
"blocked",
|
|
827
|
-
"closed"
|
|
828
|
-
]);
|
|
829
|
-
var TaskSizeSchema = exports_external.enum(["small", "medium", "large"]);
|
|
830
|
-
var PhaseStatusSchema = exports_external.enum([
|
|
831
|
-
"pending",
|
|
832
|
-
"in_progress",
|
|
833
|
-
"complete",
|
|
834
|
-
"completed",
|
|
835
|
-
"blocked",
|
|
836
|
-
"closed"
|
|
837
|
-
]);
|
|
838
|
-
var MigrationStatusSchema = exports_external.enum([
|
|
839
|
-
"native",
|
|
840
|
-
"migrated",
|
|
841
|
-
"migration_failed"
|
|
842
|
-
]);
|
|
843
|
-
var TaskSchema = exports_external.object({
|
|
844
|
-
id: exports_external.string(),
|
|
845
|
-
phase: exports_external.number().int().min(1),
|
|
846
|
-
status: TaskStatusSchema.default("pending"),
|
|
847
|
-
size: TaskSizeSchema.default("small"),
|
|
848
|
-
description: exports_external.string().min(1),
|
|
849
|
-
depends: exports_external.array(exports_external.string()).default([]),
|
|
850
|
-
acceptance: exports_external.string().optional(),
|
|
851
|
-
files_touched: exports_external.array(exports_external.string()).default([]),
|
|
852
|
-
evidence_path: exports_external.string().optional(),
|
|
853
|
-
blocked_reason: exports_external.string().optional(),
|
|
854
|
-
fr_refs: exports_external.array(exports_external.string()).optional()
|
|
855
|
-
});
|
|
856
|
-
var PhaseSchema = exports_external.object({
|
|
857
|
-
id: exports_external.number().int().min(1),
|
|
858
|
-
name: exports_external.string().min(1),
|
|
859
|
-
status: PhaseStatusSchema.default("pending"),
|
|
860
|
-
tasks: exports_external.array(TaskSchema).default([]),
|
|
861
|
-
type: exports_external.enum(["code", "non-code"]).optional(),
|
|
862
|
-
required_agents: exports_external.array(exports_external.string()).optional()
|
|
863
|
-
});
|
|
864
|
-
var PlanSchema = exports_external.object({
|
|
865
|
-
schema_version: exports_external.literal("1.0.0"),
|
|
866
|
-
title: exports_external.string().min(1),
|
|
867
|
-
swarm: exports_external.string().min(1),
|
|
868
|
-
current_phase: exports_external.number().int().min(1).optional(),
|
|
869
|
-
phases: exports_external.array(PhaseSchema).min(1),
|
|
870
|
-
migration_status: MigrationStatusSchema.optional(),
|
|
871
|
-
specMtime: exports_external.string().optional(),
|
|
872
|
-
specHash: exports_external.string().optional(),
|
|
873
|
-
execution_profile: ExecutionProfileSchema.optional()
|
|
874
|
-
});
|
|
875
|
-
function isPhaseStatusTerminal(status) {
|
|
876
|
-
return status === "complete" || status === "completed" || status === "closed";
|
|
877
|
-
}
|
|
878
|
-
function isPhaseEffectivelyTerminal(phase) {
|
|
879
|
-
if (isPhaseStatusTerminal(phase.status))
|
|
880
|
-
return true;
|
|
881
|
-
const tasks = phase.tasks ?? [];
|
|
882
|
-
return tasks.length > 0 && tasks.every((task) => task.status === "completed" || task.status === "closed");
|
|
883
|
-
}
|
|
884
|
-
function resolveActivePhaseId(plan) {
|
|
885
|
-
const cursor = plan.current_phase;
|
|
886
|
-
if (cursor !== undefined) {
|
|
887
|
-
const cursorPhase = plan.phases.find((phase) => phase.id === cursor);
|
|
888
|
-
if (cursorPhase && !isPhaseEffectivelyTerminal(cursorPhase)) {
|
|
889
|
-
return cursorPhase.id;
|
|
890
|
-
}
|
|
891
|
-
}
|
|
892
|
-
const firstNonTerminal = plan.phases.find((phase) => !isPhaseEffectivelyTerminal(phase));
|
|
893
|
-
if (firstNonTerminal)
|
|
894
|
-
return firstNonTerminal.id;
|
|
895
|
-
return plan.phases[plan.phases.length - 1]?.id ?? 1;
|
|
896
|
-
}
|
|
897
|
-
function normalizeCurrentPhaseInPlace(plan) {
|
|
898
|
-
plan.current_phase = resolveActivePhaseId(plan);
|
|
899
|
-
}
|
|
900
|
-
function getCurrentPhase(plan) {
|
|
901
|
-
return resolveActivePhaseId(plan);
|
|
902
|
-
}
|
|
903
|
-
|
|
904
|
-
export { loadPluginConfig, loadPluginConfigWithMeta, loadGateOverrides, resetConfigAdvisoryDedup, getSafeDefaultConfigLoadResult, loadPluginConfigWithMetaAsync, loadAgentPrompt, exports_loader, init_loader, ExecutionProfileSchema, TaskStatusSchema, TaskSizeSchema, PhaseStatusSchema, MigrationStatusSchema, TaskSchema, PhaseSchema, PlanSchema, resolveActivePhaseId, normalizeCurrentPhaseInPlace, getCurrentPhase };
|
|
805
|
+
export { loadPluginConfig, loadPluginConfigWithMeta, loadGateOverrides, resetConfigAdvisoryDedup, getSafeDefaultConfigLoadResult, loadPluginConfigWithMetaAsync, loadAgentPrompt, exports_loader, init_loader };
|
|
@@ -1,12 +1,96 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
} from "./index-
|
|
3
|
+
init_logger,
|
|
4
|
+
log
|
|
5
|
+
} from "./index-zgwm4ryv.js";
|
|
6
6
|
import {
|
|
7
7
|
__esm
|
|
8
8
|
} from "./index-a76rekgs.js";
|
|
9
9
|
|
|
10
|
+
// src/observability/startup-contract.ts
|
|
11
|
+
function noteStartupAdvisory() {
|
|
12
|
+
if (!state.advisoryWindowOpen)
|
|
13
|
+
return;
|
|
14
|
+
state.advisoryCount += 1;
|
|
15
|
+
}
|
|
16
|
+
var state;
|
|
17
|
+
var init_startup_contract = __esm(() => {
|
|
18
|
+
state = {
|
|
19
|
+
importMarkMs: null,
|
|
20
|
+
serverStartMark: null,
|
|
21
|
+
serverResolvedMark: null,
|
|
22
|
+
serverMs: null,
|
|
23
|
+
queueScheduledAt: null,
|
|
24
|
+
queuePending: 0,
|
|
25
|
+
queueTasks: 0,
|
|
26
|
+
queueCompleted: 0,
|
|
27
|
+
queueFailed: 0,
|
|
28
|
+
queueSettled: false,
|
|
29
|
+
queueSettledMs: null,
|
|
30
|
+
advisoryCount: 0,
|
|
31
|
+
advisoryWindowOpen: false,
|
|
32
|
+
firstTurnDone: false,
|
|
33
|
+
firstToolDone: false,
|
|
34
|
+
firstToolName: null,
|
|
35
|
+
firstTurnMs: null,
|
|
36
|
+
firstToolMs: null
|
|
37
|
+
};
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
// src/services/warning-buffer.ts
|
|
41
|
+
function sanitizeBufferedLine(s) {
|
|
42
|
+
return s.replace(/\s+/g, " ").replace(CONTROL_CHARS_RE, "").replace(/\s+/g, " ").trim();
|
|
43
|
+
}
|
|
44
|
+
function addDeferredWarning(warning) {
|
|
45
|
+
noteStartupAdvisory();
|
|
46
|
+
const sanitized = sanitizeBufferedLine(warning);
|
|
47
|
+
if (deferredWarnings.length < MAX_DEFERRED_WARNINGS - 1) {
|
|
48
|
+
deferredWarnings.push(sanitized);
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
if (!deferredWarningsTruncated) {
|
|
52
|
+
deferredWarnings.push(`[opencode-swarm] ${MAX_DEFERRED_WARNINGS - 1} deferred warnings buffered; additional advisories were dropped (cap reached). Run with OPENCODE_SWARM_DEBUG=1 to see all advisories in the debug log.`);
|
|
53
|
+
deferredWarningsTruncated = true;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
function renderAdvisoryDetail(data) {
|
|
57
|
+
if (data === undefined || data === null)
|
|
58
|
+
return "";
|
|
59
|
+
let raw;
|
|
60
|
+
if (typeof data === "string") {
|
|
61
|
+
raw = data;
|
|
62
|
+
} else if (data instanceof Error) {
|
|
63
|
+
raw = data.message;
|
|
64
|
+
} else if (Array.isArray(data) && data.every((d) => typeof d === "string")) {
|
|
65
|
+
raw = data.join("; ");
|
|
66
|
+
} else {
|
|
67
|
+
try {
|
|
68
|
+
raw = JSON.stringify(data) ?? String(data);
|
|
69
|
+
} catch {
|
|
70
|
+
raw = String(data);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
const collapsed = sanitizeBufferedLine(raw);
|
|
74
|
+
if (collapsed === "")
|
|
75
|
+
return "";
|
|
76
|
+
return collapsed.length > MAX_ADVISORY_DETAIL_CHARS ? `${collapsed.slice(0, MAX_ADVISORY_DETAIL_CHARS - 1)}\u2026` : collapsed;
|
|
77
|
+
}
|
|
78
|
+
function advisoryWarn(message, data) {
|
|
79
|
+
const detail = renderAdvisoryDetail(data);
|
|
80
|
+
addDeferredWarning(detail ? `${message} ${detail}` : message);
|
|
81
|
+
log(message, data);
|
|
82
|
+
}
|
|
83
|
+
function getDeferredWarnings() {
|
|
84
|
+
return [...deferredWarnings];
|
|
85
|
+
}
|
|
86
|
+
var deferredWarnings, MAX_DEFERRED_WARNINGS = 50, deferredWarningsTruncated = false, CONTROL_CHARS_RE, MAX_ADVISORY_DETAIL_CHARS = 600;
|
|
87
|
+
var init_warning_buffer = __esm(() => {
|
|
88
|
+
init_startup_contract();
|
|
89
|
+
init_logger();
|
|
90
|
+
deferredWarnings = [];
|
|
91
|
+
CONTROL_CHARS_RE = /[\x00-\x1F\x7F-\x9F]/g;
|
|
92
|
+
});
|
|
93
|
+
|
|
10
94
|
// src/utils/git-executable.ts
|
|
11
95
|
import { spawnSync } from "child_process";
|
|
12
96
|
import * as fs from "fs";
|
|
@@ -279,4 +363,4 @@ var init_git_executable = __esm(() => {
|
|
|
279
363
|
};
|
|
280
364
|
});
|
|
281
365
|
|
|
282
|
-
export { GIT_BINARY_ENV_VAR, resolveGitExecutable, resolveGitExecutableAsync, describeGitResolution, init_git_executable };
|
|
366
|
+
export { addDeferredWarning, advisoryWarn, getDeferredWarnings, init_warning_buffer, GIT_BINARY_ENV_VAR, resolveGitExecutable, resolveGitExecutableAsync, describeGitResolution, init_git_executable };
|
package/dist/cli/index.js
CHANGED
|
@@ -14,67 +14,69 @@ import {
|
|
|
14
14
|
readCachePackageVersion,
|
|
15
15
|
resolveCommand,
|
|
16
16
|
safeRealpathSync
|
|
17
|
-
} from "./index-
|
|
18
|
-
import"./index-
|
|
19
|
-
import"./index-
|
|
20
|
-
import"./index-
|
|
21
|
-
import"./index-
|
|
22
|
-
import"./index-
|
|
23
|
-
import"./index-
|
|
24
|
-
import"./index-
|
|
17
|
+
} from "./index-dnbqmay5.js";
|
|
18
|
+
import"./index-06crt1ej.js";
|
|
19
|
+
import"./index-hamqvzqn.js";
|
|
20
|
+
import"./index-jscqefqm.js";
|
|
21
|
+
import"./index-nhxykfyy.js";
|
|
22
|
+
import"./index-1hzqyx13.js";
|
|
23
|
+
import"./index-kp654qcw.js";
|
|
24
|
+
import"./index-aspxz5r5.js";
|
|
25
25
|
import"./index-txdagbh7.js";
|
|
26
|
-
import"./index-
|
|
26
|
+
import"./index-bx70zs8d.js";
|
|
27
27
|
import"./index-6b295cas.js";
|
|
28
|
-
import"./index-
|
|
29
|
-
import"./index-
|
|
30
|
-
import"./index-
|
|
31
|
-
import"./index-
|
|
32
|
-
import"./index-
|
|
33
|
-
import"./index-
|
|
28
|
+
import"./index-5gmn0a3j.js";
|
|
29
|
+
import"./index-ret97f1t.js";
|
|
30
|
+
import"./index-2h0qng38.js";
|
|
31
|
+
import"./index-rdec0y3z.js";
|
|
32
|
+
import"./index-93vk5s7v.js";
|
|
33
|
+
import"./index-cjapb4hy.js";
|
|
34
34
|
import"./index-zsrtt42s.js";
|
|
35
|
-
import"./index-
|
|
36
|
-
import"./index-
|
|
37
|
-
import"./index-
|
|
35
|
+
import"./index-cxgr6ad5.js";
|
|
36
|
+
import"./index-bdpgfep1.js";
|
|
37
|
+
import"./index-92m05mew.js";
|
|
38
38
|
import"./index-pt7h91zc.js";
|
|
39
39
|
import"./index-q7sjgr1y.js";
|
|
40
|
-
import"./index-
|
|
41
|
-
import"./index-
|
|
42
|
-
import"./index-
|
|
43
|
-
import"./index-
|
|
44
|
-
import"./index-
|
|
40
|
+
import"./index-b9z9gvx0.js";
|
|
41
|
+
import"./index-caj76d0f.js";
|
|
42
|
+
import"./index-8b1f2t5q.js";
|
|
43
|
+
import"./index-v1sc1gxv.js";
|
|
44
|
+
import"./index-ekgc71m1.js";
|
|
45
|
+
import"./index-gc6h1fmf.js";
|
|
45
46
|
import"./index-2s7dvzff.js";
|
|
46
|
-
import"./index-
|
|
47
|
-
import"./index-
|
|
47
|
+
import"./index-5m378633.js";
|
|
48
|
+
import"./index-5yc5n4ae.js";
|
|
48
49
|
import"./index-rtry5xyf.js";
|
|
49
|
-
import"./index-
|
|
50
|
+
import"./index-dcttq1mn.js";
|
|
50
51
|
import"./index-frcemc0b.js";
|
|
51
|
-
import"./index-
|
|
52
|
-
import"./index-
|
|
53
|
-
import"./index-
|
|
54
|
-
import"./index-
|
|
55
|
-
import"./index-
|
|
56
|
-
import"./index-
|
|
57
|
-
import"./index-
|
|
58
|
-
import"./index-ry16d01s.js";
|
|
52
|
+
import"./index-0725jpp7.js";
|
|
53
|
+
import"./index-jrfv2am8.js";
|
|
54
|
+
import"./index-x6kjbjya.js";
|
|
55
|
+
import"./index-htrb9ec3.js";
|
|
56
|
+
import"./index-91dhg3wr.js";
|
|
57
|
+
import"./index-vmthakz0.js";
|
|
58
|
+
import"./index-bv4b8tpa.js";
|
|
59
59
|
import"./index-rdm3px0g.js";
|
|
60
|
-
import"./index-
|
|
61
|
-
import"./index-
|
|
60
|
+
import"./index-ry16d01s.js";
|
|
61
|
+
import"./index-jmrsfhwq.js";
|
|
62
|
+
import"./index-pnt98k7z.js";
|
|
62
63
|
import"./index-vzm6zre7.js";
|
|
63
64
|
import"./index-ae75rja9.js";
|
|
64
|
-
import"./index-
|
|
65
|
-
import"./index-
|
|
66
|
-
import"./index-7g4c7s5r.js";
|
|
65
|
+
import"./index-zvxy0mev.js";
|
|
66
|
+
import"./index-0v1rtanv.js";
|
|
67
67
|
import"./index-qt0793qm.js";
|
|
68
|
-
import"./index-ne9zamcs.js";
|
|
69
68
|
import"./index-1xnse449.js";
|
|
70
69
|
import"./index-c1ggtmpm.js";
|
|
71
|
-
import"./index-
|
|
72
|
-
import"./index-
|
|
73
|
-
import"./index-
|
|
70
|
+
import"./index-ejhxgyvm.js";
|
|
71
|
+
import"./index-7g4c7s5r.js";
|
|
72
|
+
import"./index-989v83pb.js";
|
|
73
|
+
import"./index-gx2vp8gx.js";
|
|
74
|
+
import"./index-zptq8mp1.js";
|
|
75
|
+
import"./index-zxdawwc7.js";
|
|
74
76
|
import {
|
|
75
77
|
init_package,
|
|
76
78
|
package_default
|
|
77
|
-
} from "./index-
|
|
79
|
+
} from "./index-defq2crz.js";
|
|
78
80
|
import {
|
|
79
81
|
DEFAULT_AGENT_CONFIGS,
|
|
80
82
|
init_constants
|
|
@@ -642,7 +644,7 @@ async function main() {
|
|
|
642
644
|
const exitCode = await run(["ci", ...args.slice(1)]);
|
|
643
645
|
process.exit(exitCode);
|
|
644
646
|
} else if (command === "mcp") {
|
|
645
|
-
const { handleMcpCommand } = await import("./mcp-
|
|
647
|
+
const { handleMcpCommand } = await import("./mcp-hnb0m05a.js");
|
|
646
648
|
const exitCode = await handleMcpCommand(args.slice(1));
|
|
647
649
|
process.exit(exitCode);
|
|
648
650
|
} else {
|
|
@@ -9,28 +9,29 @@ import {
|
|
|
9
9
|
maybeEscalateOnViolation,
|
|
10
10
|
maybeQuarantineOnContradiction,
|
|
11
11
|
readRecentEscalations
|
|
12
|
-
} from "./index-
|
|
13
|
-
import"./index-
|
|
14
|
-
import"./index-
|
|
12
|
+
} from "./index-ret97f1t.js";
|
|
13
|
+
import"./index-ekgc71m1.js";
|
|
14
|
+
import"./index-gc6h1fmf.js";
|
|
15
15
|
import"./index-2s7dvzff.js";
|
|
16
|
-
import"./index-
|
|
16
|
+
import"./index-dcttq1mn.js";
|
|
17
17
|
import"./index-frcemc0b.js";
|
|
18
|
-
import"./index-
|
|
19
|
-
import"./index-
|
|
20
|
-
import"./index-
|
|
18
|
+
import"./index-0725jpp7.js";
|
|
19
|
+
import"./index-jmrsfhwq.js";
|
|
20
|
+
import"./index-pnt98k7z.js";
|
|
21
21
|
import"./index-vzm6zre7.js";
|
|
22
22
|
import"./index-ae75rja9.js";
|
|
23
|
-
import"./index-
|
|
24
|
-
import"./index-
|
|
25
|
-
import"./index-7g4c7s5r.js";
|
|
23
|
+
import"./index-zvxy0mev.js";
|
|
24
|
+
import"./index-0v1rtanv.js";
|
|
26
25
|
import"./index-qt0793qm.js";
|
|
27
|
-
import"./index-ne9zamcs.js";
|
|
28
26
|
import"./index-1xnse449.js";
|
|
29
27
|
import"./index-c1ggtmpm.js";
|
|
30
|
-
import"./index-
|
|
31
|
-
import"./index-
|
|
32
|
-
import"./index-
|
|
33
|
-
import"./index-
|
|
28
|
+
import"./index-ejhxgyvm.js";
|
|
29
|
+
import"./index-7g4c7s5r.js";
|
|
30
|
+
import"./index-989v83pb.js";
|
|
31
|
+
import"./index-gx2vp8gx.js";
|
|
32
|
+
import"./index-zptq8mp1.js";
|
|
33
|
+
import"./index-zxdawwc7.js";
|
|
34
|
+
import"./index-defq2crz.js";
|
|
34
35
|
import"./index-w872yykk.js";
|
|
35
36
|
import"./index-bk5tah7q.js";
|
|
36
37
|
import"./index-gknz3bv1.js";
|
|
@@ -29,25 +29,26 @@ import {
|
|
|
29
29
|
resolveKnowledgeCounterBaselinePath,
|
|
30
30
|
resolveKnowledgeEventsPath,
|
|
31
31
|
resolveLegacyApplicationLogPath
|
|
32
|
-
} from "./index-
|
|
33
|
-
import"./index-
|
|
32
|
+
} from "./index-ekgc71m1.js";
|
|
33
|
+
import"./index-gc6h1fmf.js";
|
|
34
34
|
import"./index-2s7dvzff.js";
|
|
35
|
-
import"./index-
|
|
35
|
+
import"./index-dcttq1mn.js";
|
|
36
36
|
import"./index-frcemc0b.js";
|
|
37
|
-
import"./index-
|
|
38
|
-
import"./index-
|
|
37
|
+
import"./index-0725jpp7.js";
|
|
38
|
+
import"./index-jmrsfhwq.js";
|
|
39
39
|
import"./index-ae75rja9.js";
|
|
40
|
-
import"./index-
|
|
41
|
-
import"./index-
|
|
42
|
-
import"./index-7g4c7s5r.js";
|
|
40
|
+
import"./index-zvxy0mev.js";
|
|
41
|
+
import"./index-0v1rtanv.js";
|
|
43
42
|
import"./index-qt0793qm.js";
|
|
44
|
-
import"./index-ne9zamcs.js";
|
|
45
43
|
import"./index-1xnse449.js";
|
|
46
44
|
import"./index-c1ggtmpm.js";
|
|
47
|
-
import"./index-
|
|
48
|
-
import"./index-
|
|
49
|
-
import"./index-
|
|
50
|
-
import"./index-
|
|
45
|
+
import"./index-ejhxgyvm.js";
|
|
46
|
+
import"./index-7g4c7s5r.js";
|
|
47
|
+
import"./index-989v83pb.js";
|
|
48
|
+
import"./index-gx2vp8gx.js";
|
|
49
|
+
import"./index-zptq8mp1.js";
|
|
50
|
+
import"./index-zxdawwc7.js";
|
|
51
|
+
import"./index-defq2crz.js";
|
|
51
52
|
import"./index-w872yykk.js";
|
|
52
53
|
import"./index-bk5tah7q.js";
|
|
53
54
|
import"./index-gknz3bv1.js";
|
|
@@ -12,13 +12,14 @@ import {
|
|
|
12
12
|
resolveLinkDir,
|
|
13
13
|
sanitizeLinkId,
|
|
14
14
|
writeLinkPointer
|
|
15
|
-
} from "./index-
|
|
16
|
-
import"./index-
|
|
17
|
-
import"./index-7g4c7s5r.js";
|
|
15
|
+
} from "./index-zvxy0mev.js";
|
|
16
|
+
import"./index-0v1rtanv.js";
|
|
18
17
|
import"./index-qt0793qm.js";
|
|
19
|
-
import"./index-ne9zamcs.js";
|
|
20
18
|
import"./index-1xnse449.js";
|
|
21
19
|
import"./index-c1ggtmpm.js";
|
|
20
|
+
import"./index-ejhxgyvm.js";
|
|
21
|
+
import"./index-7g4c7s5r.js";
|
|
22
|
+
import"./index-989v83pb.js";
|
|
22
23
|
import"./index-gknz3bv1.js";
|
|
23
24
|
import"./index-zpsr8rpc.js";
|
|
24
25
|
import"./index-zgwm4ryv.js";
|