claude-code-templates 1.24.7 → 1.24.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.
|
@@ -244,14 +244,21 @@ Requirements:
|
|
|
244
244
|
// Collect the full response
|
|
245
245
|
let generatedCode = '';
|
|
246
246
|
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
247
|
+
try {
|
|
248
|
+
for await (const message of query({ prompt: promptContent, options })) {
|
|
249
|
+
if (message.type === 'text') {
|
|
250
|
+
generatedCode += message.text;
|
|
251
|
+
}
|
|
250
252
|
}
|
|
253
|
+
} catch (queryError) {
|
|
254
|
+
const err = queryError as Error;
|
|
255
|
+
log(`Query error: ${err.message}`, 'error');
|
|
256
|
+
log(`Stack: ${err.stack}`, 'error');
|
|
257
|
+
throw new Error(`Claude Agent SDK query failed: ${err.message}`);
|
|
251
258
|
}
|
|
252
259
|
|
|
253
260
|
if (!generatedCode) {
|
|
254
|
-
throw new Error('Failed to generate code from Claude Agent SDK');
|
|
261
|
+
throw new Error('Failed to generate code from Claude Agent SDK (empty response)');
|
|
255
262
|
}
|
|
256
263
|
|
|
257
264
|
log('Code generated successfully', 'success');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claude-code-templates",
|
|
3
|
-
"version": "1.24.
|
|
3
|
+
"version": "1.24.8",
|
|
4
4
|
"description": "CLI tool to setup Claude Code configurations with framework-specific commands, automation hooks and MCP Servers for your projects",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"bin": {
|