mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-15 02:42:45 +08:00
feat: update empty state messages and hints in English and Chinese locales
refactor: rename variables for clarity in ReviewSessionPage and SessionsPage fix: update version check logic in SettingsPage chore: remove unused imports in TeamPage and session-detail components fix: enhance error handling in MCP server fix: apply default mode in edit-file tool handler chore: remove tsbuildinfo file docs: add Quick Plan & Execute phase documentation for issue discovery chore: clean up ping output file
This commit is contained in:
@@ -155,7 +155,16 @@ async function main(): Promise<void> {
|
||||
// Connect server to transport
|
||||
await server.connect(transport);
|
||||
|
||||
// Error handling
|
||||
// Error handling - prevent process crashes from closing transport
|
||||
process.on('uncaughtException', (error) => {
|
||||
console.error(`[${SERVER_NAME}] Uncaught exception:`, error.message);
|
||||
console.error(error.stack);
|
||||
});
|
||||
|
||||
process.on('unhandledRejection', (reason) => {
|
||||
console.error(`[${SERVER_NAME}] Unhandled rejection:`, reason);
|
||||
});
|
||||
|
||||
process.on('SIGINT', async () => {
|
||||
await server.close();
|
||||
process.exit(0);
|
||||
|
||||
@@ -570,7 +570,9 @@ interface CompactEditResult {
|
||||
|
||||
// Handler function
|
||||
export async function handler(params: Record<string, unknown>): Promise<ToolResult<CompactEditResult>> {
|
||||
const parsed = ParamsSchema.safeParse(params);
|
||||
// Apply default mode before discriminatedUnion check (Zod doesn't apply defaults on discriminator)
|
||||
const normalizedParams = params.mode === undefined ? { ...params, mode: 'update' } : params;
|
||||
const parsed = ParamsSchema.safeParse(normalizedParams);
|
||||
if (!parsed.success) {
|
||||
return { success: false, error: `Invalid params: ${parsed.error.message}` };
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user