fluxy-bot 0.5.31 → 0.5.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/package.json
CHANGED
|
@@ -188,6 +188,7 @@ export async function startFluxyAgentQuery(
|
|
|
188
188
|
}
|
|
189
189
|
} catch {}
|
|
190
190
|
|
|
191
|
+
let stderrBuf = '';
|
|
191
192
|
const claudeQuery = query({
|
|
192
193
|
prompt: sdkPrompt,
|
|
193
194
|
options: {
|
|
@@ -200,6 +201,7 @@ export async function startFluxyAgentQuery(
|
|
|
200
201
|
systemPrompt: enrichedPrompt,
|
|
201
202
|
plugins: plugins.length ? plugins : undefined,
|
|
202
203
|
mcpServers,
|
|
204
|
+
stderr: (chunk: string) => { stderrBuf += chunk; },
|
|
203
205
|
env: {
|
|
204
206
|
...process.env as Record<string, string>,
|
|
205
207
|
CLAUDE_CODE_OAUTH_TOKEN: oauthToken,
|
|
@@ -261,8 +263,10 @@ export async function startFluxyAgentQuery(
|
|
|
261
263
|
}
|
|
262
264
|
} catch (err: any) {
|
|
263
265
|
if (!abortController.signal.aborted) {
|
|
264
|
-
|
|
265
|
-
|
|
266
|
+
const detail = stderrBuf.trim();
|
|
267
|
+
const msg = detail ? `${err.message}\n\nCLI stderr:\n${detail}` : err.message;
|
|
268
|
+
log.warn(`Fluxy agent error (${conversationId}): ${msg}`);
|
|
269
|
+
onMessage('bot:error', { conversationId, error: msg });
|
|
266
270
|
}
|
|
267
271
|
} finally {
|
|
268
272
|
activeQueries.delete(conversationId);
|