mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-05 06:59:42 +02:00
chore: remove dead code and unused exports (-159 lines)
Remove confirmed-unused code found via team-based codebase analysis: - Dead interfaces: SessionResponse (types.ts), PlannerResult (plan-orchestrator.ts) - Dead functions: withTimeout (session.ts), getOpenCodeAugmentedPath, resetOpenCodeCache (opencode-cli-resolver.ts) - Dead config constants: MAX_RUN_SUMMARY_EVENTS, TRIM_RUN_SUMMARY_TO, MAX_MESSAGES_PER_CHANNEL (buffer-limits.ts), MAX_TRACKED_AGENTS, MAX_SUBAGENT_ACTIVITY_PER_AGENT, MAX_TOOL_RESULTS_PER_AGENT, COMPLETED_TODO_TTL_MS (map-limits.ts) - Dead legacy code: idleTimer property + clearIdleTimer() no-op method + 6 call sites (respawn-controller.ts) - Stale barrel re-exports: createAnsiPatternFull/Simple, validateTokenCounts/Cost, stripAnsi, normalizePhrase, getOpenCodeAugmentedPath (utils/index.ts) - Un-exported internal-only symbols: ErrorMessages (types.ts), destroyRalphLoop (ralph-loop.ts) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
+1
-24
@@ -667,7 +667,7 @@ export enum ApiErrorCode {
|
||||
/**
|
||||
* User-friendly error messages for each error code
|
||||
*/
|
||||
export const ErrorMessages: Record<ApiErrorCode, string> = {
|
||||
const ErrorMessages: Record<ApiErrorCode, string> = {
|
||||
[ApiErrorCode.NOT_FOUND]: 'The requested resource was not found',
|
||||
[ApiErrorCode.INVALID_INPUT]: 'Invalid input provided',
|
||||
[ApiErrorCode.SESSION_BUSY]: 'Session is currently busy',
|
||||
@@ -711,29 +711,6 @@ export function createErrorResponse(code: ApiErrorCode, details?: string): ApiRe
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Response for session operations
|
||||
*/
|
||||
export interface SessionResponse {
|
||||
/** Whether the request succeeded */
|
||||
success: boolean;
|
||||
/** Session details if successful (light state — no full buffers) */
|
||||
session?: SessionState & {
|
||||
/** Claude session ID from CLI */
|
||||
claudeSessionId: string | null;
|
||||
/** Total API cost */
|
||||
totalCost: number;
|
||||
/** Number of messages */
|
||||
messageCount: number;
|
||||
/** Whether Claude is working */
|
||||
isWorking: boolean;
|
||||
/** Timestamp of last prompt */
|
||||
lastPromptTime: number;
|
||||
};
|
||||
/** Error message if failed */
|
||||
error?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Response for quick start operation
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user