kiro-spec-engine 1.45.10 → 1.45.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -7,6 +7,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [1.45.12] - 2026-02-13
11
+
12
+ ### Fixed
13
+ - **Windows prompt validation**: `AgentSpawner.spawn()` now validates `stdinPrompt` after `finalArgs.pop()` to ensure it's a non-empty string before writing to temp file, preventing undefined/null values from causing silent failures (fixes issue where bootstrap prompt generation failures weren't caught, leading to empty temp files and `error: unexpected argument` errors)
14
+
15
+ ## [1.45.11] - 2026-02-13
16
+
17
+ ### Fixed
18
+ - **Windows filename special characters**: `AgentSpawner.spawn()` now sanitizes agentId by removing Windows reserved characters `[:<>"|?*]` before using in temp file path, fixing file path parsing errors when agentId contains colon (e.g., `"zeno-v4-uuid:1"` format)
19
+
10
20
  ## [1.45.10] - 2026-02-13
11
21
 
12
22
  ### Fixed
@@ -119,6 +119,16 @@ class AgentSpawner extends EventEmitter {
119
119
  // Remove the prompt (last element of args portion) from command line
120
120
  // and deliver it via stdin to avoid cmd.exe length limit.
121
121
  stdinPrompt = finalArgs.pop(); // remove prompt
122
+
123
+ // Validate stdinPrompt before proceeding
124
+ if (!stdinPrompt || typeof stdinPrompt !== 'string' || stdinPrompt.length === 0) {
125
+ throw new Error(
126
+ `Invalid bootstrap prompt: expected non-empty string, got ${typeof stdinPrompt} ` +
127
+ `with length ${stdinPrompt ? stdinPrompt.length : 0}. ` +
128
+ `This may indicate BootstrapPromptBuilder.buildPrompt() failed or args array is malformed.`
129
+ );
130
+ }
131
+
122
132
  // If the prompt was quoted by the escaping above, unwrap it
123
133
  if (stdinPrompt.startsWith('"') && stdinPrompt.endsWith('"')) {
124
134
  stdinPrompt = stdinPrompt.slice(1, -1).replace(/\\"/g, '"');
@@ -134,7 +144,9 @@ class AgentSpawner extends EventEmitter {
134
144
  // write prompt → pass file path via shell read.
135
145
  let promptTmpFile = null;
136
146
  if (useStdinPrompt) {
137
- promptTmpFile = path.join(os.tmpdir(), `kse-prompt-${agentId}-${Date.now()}.txt`);
147
+ // Sanitize agentId for use in filename - remove Windows reserved characters: < > : " | ? *
148
+ const safeAgentId = agentId.replace(/[:<>"|?*]/g, '-');
149
+ promptTmpFile = path.join(os.tmpdir(), `kse-prompt-${safeAgentId}-${Date.now()}.txt`);
138
150
  fs.writeFileSync(promptTmpFile, stdinPrompt, 'utf-8');
139
151
  }
140
152
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kiro-spec-engine",
3
- "version": "1.45.10",
3
+ "version": "1.45.12",
4
4
  "description": "kiro-spec-engine (kse) - A CLI tool and npm package for spec-driven development with AI coding assistants. NOT the Kiro IDE desktop application.",
5
5
  "main": "index.js",
6
6
  "bin": {