juno-code 1.0.30 → 1.0.32
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/dist/bin/cli.js +73 -12
- package/dist/bin/cli.js.map +1 -1
- package/dist/bin/cli.mjs +73 -12
- package/dist/bin/cli.mjs.map +1 -1
- package/dist/index.js +40 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +40 -3
- package/dist/index.mjs.map +1 -1
- package/dist/templates/services/claude.py +77 -17
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -44,7 +44,7 @@ var __export = (target, all) => {
|
|
|
44
44
|
var version;
|
|
45
45
|
var init_version = __esm({
|
|
46
46
|
"src/version.ts"() {
|
|
47
|
-
version = "1.0.
|
|
47
|
+
version = "1.0.32";
|
|
48
48
|
}
|
|
49
49
|
});
|
|
50
50
|
function isHeadlessEnvironment() {
|
|
@@ -4437,6 +4437,8 @@ var ENV_VAR_MAPPING = {
|
|
|
4437
4437
|
JUNO_CODE_MCP_RETRIES: "mcpRetries",
|
|
4438
4438
|
JUNO_CODE_MCP_SERVER_PATH: "mcpServerPath",
|
|
4439
4439
|
JUNO_CODE_MCP_SERVER_NAME: "mcpServerName",
|
|
4440
|
+
// Hook settings
|
|
4441
|
+
JUNO_CODE_HOOK_COMMAND_TIMEOUT: "hookCommandTimeout",
|
|
4440
4442
|
// TUI settings
|
|
4441
4443
|
JUNO_CODE_INTERACTIVE: "interactive",
|
|
4442
4444
|
JUNO_CODE_HEADLESS_MODE: "headlessMode",
|
|
@@ -4460,6 +4462,8 @@ var LEGACY_ENV_VAR_MAPPING = {
|
|
|
4460
4462
|
JUNO_TASK_MCP_RETRIES: "mcpRetries",
|
|
4461
4463
|
JUNO_TASK_MCP_SERVER_PATH: "mcpServerPath",
|
|
4462
4464
|
JUNO_TASK_MCP_SERVER_NAME: "mcpServerName",
|
|
4465
|
+
// Hook settings
|
|
4466
|
+
JUNO_TASK_HOOK_COMMAND_TIMEOUT: "hookCommandTimeout",
|
|
4463
4467
|
// TUI settings
|
|
4464
4468
|
JUNO_TASK_INTERACTIVE: "interactive",
|
|
4465
4469
|
JUNO_TASK_HEADLESS_MODE: "headlessMode",
|
|
@@ -4491,6 +4495,8 @@ var JunoTaskConfigSchema = z.object({
|
|
|
4491
4495
|
mcpRetries: z.number().int().min(0).max(10).describe("Number of retries for MCP operations"),
|
|
4492
4496
|
mcpServerPath: z.string().optional().describe("Path to MCP server executable (auto-discovered if not specified)"),
|
|
4493
4497
|
mcpServerName: z.string().optional().describe('Named MCP server to connect to (e.g., "roundtable-ai")'),
|
|
4498
|
+
// Hook settings
|
|
4499
|
+
hookCommandTimeout: z.number().int().min(1e3).max(36e5).optional().describe("Timeout for individual hook commands in milliseconds (default: 300000 = 5 minutes)"),
|
|
4494
4500
|
// TUI settings
|
|
4495
4501
|
interactive: z.boolean().describe("Enable interactive mode"),
|
|
4496
4502
|
headlessMode: z.boolean().describe("Enable headless mode (no TUI)"),
|
|
@@ -6551,7 +6557,8 @@ var hookLogger = logger.child("SYSTEM" /* SYSTEM */, { component: "hooks" });
|
|
|
6551
6557
|
async function executeHook(hookType, hooks, context = {}, options = {}) {
|
|
6552
6558
|
const startTime = Date.now();
|
|
6553
6559
|
const {
|
|
6554
|
-
commandTimeout =
|
|
6560
|
+
commandTimeout = 3e5,
|
|
6561
|
+
// 5 minutes default (increased from 30s to support long-running hook scripts)
|
|
6555
6562
|
env: env2 = {},
|
|
6556
6563
|
continueOnError = true,
|
|
6557
6564
|
logContext = "SYSTEM" /* SYSTEM */
|
|
@@ -6626,8 +6633,12 @@ async function executeHook(hookType, hooks, context = {}, options = {}) {
|
|
|
6626
6633
|
env: execEnv,
|
|
6627
6634
|
// Capture both stdout and stderr
|
|
6628
6635
|
all: true,
|
|
6629
|
-
reject: false
|
|
6636
|
+
reject: false,
|
|
6630
6637
|
// Don't throw on non-zero exit codes
|
|
6638
|
+
// Use input: '' to provide empty stdin and properly close it (sends EOF)
|
|
6639
|
+
// This prevents commands from hanging waiting for stdin while still
|
|
6640
|
+
// allowing internal pipe operations to work correctly
|
|
6641
|
+
input: ""
|
|
6631
6642
|
});
|
|
6632
6643
|
const duration = Date.now() - commandStartTime;
|
|
6633
6644
|
const success2 = result2.exitCode === 0;
|
|
@@ -7148,6 +7159,8 @@ var ExecutionEngine = class extends EventEmitter {
|
|
|
7148
7159
|
maxIterations: context.request.maxIterations,
|
|
7149
7160
|
instruction: context.request.instruction
|
|
7150
7161
|
}
|
|
7162
|
+
}, {
|
|
7163
|
+
commandTimeout: this.engineConfig.config.hookCommandTimeout
|
|
7151
7164
|
});
|
|
7152
7165
|
}
|
|
7153
7166
|
} catch (error) {
|
|
@@ -7180,6 +7193,8 @@ var ExecutionEngine = class extends EventEmitter {
|
|
|
7180
7193
|
duration: context.endTime ? context.endTime.getTime() - context.startTime.getTime() : 0,
|
|
7181
7194
|
success: context.status === "completed" /* COMPLETED */
|
|
7182
7195
|
}
|
|
7196
|
+
}, {
|
|
7197
|
+
commandTimeout: this.engineConfig.config.hookCommandTimeout
|
|
7183
7198
|
});
|
|
7184
7199
|
}
|
|
7185
7200
|
} catch (error) {
|
|
@@ -7231,6 +7246,8 @@ var ExecutionEngine = class extends EventEmitter {
|
|
|
7231
7246
|
maxIterations: context.request.maxIterations,
|
|
7232
7247
|
subagent: context.request.subagent
|
|
7233
7248
|
}
|
|
7249
|
+
}, {
|
|
7250
|
+
commandTimeout: this.engineConfig.config.hookCommandTimeout
|
|
7234
7251
|
});
|
|
7235
7252
|
}
|
|
7236
7253
|
} catch (error) {
|
|
@@ -7245,7 +7262,11 @@ var ExecutionEngine = class extends EventEmitter {
|
|
|
7245
7262
|
...context.request.model !== void 0 && { model: context.request.model },
|
|
7246
7263
|
...context.request.agents !== void 0 && { agents: context.request.agents },
|
|
7247
7264
|
...context.request.tools !== void 0 && { tools: context.request.tools },
|
|
7265
|
+
...context.request.allowedTools !== void 0 && { allowedTools: context.request.allowedTools },
|
|
7266
|
+
...context.request.appendAllowedTools !== void 0 && { appendAllowedTools: context.request.appendAllowedTools },
|
|
7248
7267
|
...context.request.disallowedTools !== void 0 && { disallowedTools: context.request.disallowedTools },
|
|
7268
|
+
...context.request.resume !== void 0 && { resume: context.request.resume },
|
|
7269
|
+
...context.request.continueConversation !== void 0 && { continueConversation: context.request.continueConversation },
|
|
7249
7270
|
iteration: iterationNumber
|
|
7250
7271
|
},
|
|
7251
7272
|
timeout: context.request.timeoutMs || this.engineConfig.config.mcpTimeout,
|
|
@@ -7293,6 +7314,8 @@ var ExecutionEngine = class extends EventEmitter {
|
|
|
7293
7314
|
duration: iterationResult.duration,
|
|
7294
7315
|
toolCallStatus: iterationResult.toolResult.status
|
|
7295
7316
|
}
|
|
7317
|
+
}, {
|
|
7318
|
+
commandTimeout: this.engineConfig.config.hookCommandTimeout
|
|
7296
7319
|
});
|
|
7297
7320
|
}
|
|
7298
7321
|
} catch (error) {
|
|
@@ -7341,6 +7364,8 @@ var ExecutionEngine = class extends EventEmitter {
|
|
|
7341
7364
|
error: mcpError.message,
|
|
7342
7365
|
errorType: mcpError.type
|
|
7343
7366
|
}
|
|
7367
|
+
}, {
|
|
7368
|
+
commandTimeout: this.engineConfig.config.hookCommandTimeout
|
|
7344
7369
|
});
|
|
7345
7370
|
}
|
|
7346
7371
|
} catch (hookError) {
|
|
@@ -7685,12 +7710,24 @@ function createExecutionRequest(options) {
|
|
|
7685
7710
|
if (options.tools !== void 0) {
|
|
7686
7711
|
result.tools = options.tools;
|
|
7687
7712
|
}
|
|
7713
|
+
if (options.allowedTools !== void 0) {
|
|
7714
|
+
result.allowedTools = options.allowedTools;
|
|
7715
|
+
}
|
|
7716
|
+
if (options.appendAllowedTools !== void 0) {
|
|
7717
|
+
result.appendAllowedTools = options.appendAllowedTools;
|
|
7718
|
+
}
|
|
7688
7719
|
if (options.disallowedTools !== void 0) {
|
|
7689
7720
|
result.disallowedTools = options.disallowedTools;
|
|
7690
7721
|
}
|
|
7691
7722
|
if (options.mcpServerName !== void 0) {
|
|
7692
7723
|
result.mcpServerName = options.mcpServerName;
|
|
7693
7724
|
}
|
|
7725
|
+
if (options.resume !== void 0) {
|
|
7726
|
+
result.resume = options.resume;
|
|
7727
|
+
}
|
|
7728
|
+
if (options.continueConversation !== void 0) {
|
|
7729
|
+
result.continueConversation = options.continueConversation;
|
|
7730
|
+
}
|
|
7694
7731
|
return result;
|
|
7695
7732
|
}
|
|
7696
7733
|
|