@kody-ade/kody-engine 0.4.204-next.6 → 0.4.204-next.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/bin/kody.js +39 -3
  2. package/package.json +1 -1
package/dist/bin/kody.js CHANGED
@@ -1483,7 +1483,7 @@ var init_loadCoverageRules = __esm({
1483
1483
  // package.json
1484
1484
  var package_default = {
1485
1485
  name: "@kody-ade/kody-engine",
1486
- version: "0.4.204-next.6",
1486
+ version: "0.4.204-next.8",
1487
1487
  description: "kody \u2014 autonomous development engine. Single-session Claude Code agent behind a generic executor + declarative executable profiles.",
1488
1488
  license: "MIT",
1489
1489
  type: "module",
@@ -10183,6 +10183,18 @@ function humanizeSlug(slug) {
10183
10183
  return slug.split(/[-_]+/).filter((s) => s.length > 0).map((s) => s[0].toUpperCase() + s.slice(1)).join(" ");
10184
10184
  }
10185
10185
 
10186
+ // src/scripts/loadDutyState.ts
10187
+ var loadDutyState = async (ctx, profile, args) => {
10188
+ const jobsDir = String(args?.jobsDir ?? ".kody/duties");
10189
+ const slug = profile.name;
10190
+ const backend = resolveBackend({ config: ctx.config, cwd: ctx.cwd, jobsDir });
10191
+ if (backend.hydrate) await backend.hydrate();
10192
+ const loaded = await backend.load(slug);
10193
+ ctx.data.jobSlug = slug;
10194
+ ctx.data.jobState = loaded;
10195
+ ctx.data.jobStateJson = JSON.stringify(loaded.state, null, 2);
10196
+ };
10197
+
10186
10198
  // src/scripts/loadLinkedFinding.ts
10187
10199
  init_issue();
10188
10200
  var FINDING_BODY_MAX_BYTES = 4e3;
@@ -14598,6 +14610,7 @@ var preflightScripts = {
14598
14610
  loadIssueContext,
14599
14611
  loadIssueStateComment,
14600
14612
  loadJobFromFile,
14613
+ loadDutyState,
14601
14614
  loadWorkerAdhoc,
14602
14615
  loadConventions,
14603
14616
  loadCoverageRules,
@@ -15653,9 +15666,32 @@ async function runCi(argv) {
15653
15666
 
15654
15667
  `);
15655
15668
  try {
15656
- unpackAllSecrets();
15669
+ const n = unpackAllSecrets();
15670
+ if (n > 0) process.stdout.write(`\u2192 kody: unpacked ${n} secret(s)
15671
+ `);
15657
15672
  await resolveAuthToken();
15658
- } catch {
15673
+ const pm = args.packageManager ?? detectPackageManager2(cwd);
15674
+ if (!args.skipInstall) {
15675
+ const code = installDeps(pm, cwd);
15676
+ if (code !== 0) {
15677
+ process.stderr.write(`[kody] dependency install failed (exit ${code})
15678
+ `);
15679
+ return 99;
15680
+ }
15681
+ }
15682
+ if (!args.skipLitellm) {
15683
+ const code = installLitellmIfNeeded(cwd);
15684
+ if (code !== 0) {
15685
+ process.stderr.write(`[kody] litellm install failed (exit ${code})
15686
+ `);
15687
+ return 99;
15688
+ }
15689
+ }
15690
+ configureGitIdentity(cwd);
15691
+ } catch (err) {
15692
+ process.stderr.write(`[kody] manual duty preflight crashed: ${String(err)}
15693
+ `);
15694
+ return 99;
15659
15695
  }
15660
15696
  const result = await runExecutableChain(forceRunDuty, {
15661
15697
  cliArgs: {},
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kody-ade/kody-engine",
3
- "version": "0.4.204-next.6",
3
+ "version": "0.4.204-next.8",
4
4
  "description": "kody — autonomous development engine. Single-session Claude Code agent behind a generic executor + declarative executable profiles.",
5
5
  "license": "MIT",
6
6
  "type": "module",