Files
openclaw/scripts/deadcode-exports.baseline.mjs
Peter Steinberger 2808507c3b refactor(agents): privatize runtime test seams (#108295)
Shrinks the dead-export baseline from 156 to 151 entries.
2026-07-15 05:36:35 -07:00

160 lines
10 KiB
JavaScript

// Pre-existing unused exports awaiting deletion.
// New entries fail CI. After deleting dead code, run `pnpm deadcode:exports:update`.
// Do not add entries to avoid fixing new findings.
export const KNIP_UNUSED_EXPORT_BASELINE = [
"src/agents/agent-hooks/compaction-safeguard.ts: testing",
"src/agents/agent-tools.before-tool-call.ts: BeforeToolCallBlockedError",
"src/agents/agent-tools.before-tool-call.ts: testing",
"src/agents/apply-patch.ts: applyPatch",
"src/agents/cli-backends.ts: resolveCliBackendLiveTest",
"src/agents/cli-backends.ts: testing",
"src/agents/cli-credentials.ts: readCodexCliCredentials (cliCredentials)",
"src/agents/cli-credentials.ts: resetCliCredentialCachesForTest",
"src/agents/code-mode-namespaces.ts: clearCodeModeNamespacesForTest",
"src/agents/code-mode-namespaces.ts: createCodeModeNamespaceTool",
"src/agents/code-mode-namespaces.ts: listCodeModeNamespaces",
"src/agents/code-mode-namespaces.ts: registerCodeModeNamespaceForPlugin",
"src/agents/code-mode.ts: isCodeModeControlTool",
"src/agents/code-mode.ts: testing",
"src/agents/command/attempt-execution.helpers.ts: claudeCliSessionTranscriptPath",
"src/agents/command/attempt-execution.helpers.ts: formatClaudeCliFallbackPrelude",
"src/agents/compaction-planning-worker.ts: compactionPlanningWorkerTesting",
"src/agents/compaction-planning.worker.ts: runCompactionPlanningWorkerInput",
"src/agents/compaction.ts: buildCompactionSummarizationInstructions",
"src/agents/compaction.ts: summarizeWithFallback",
"src/agents/embedded-agent-runner/extra-params.ts: testing",
"src/agents/embedded-agent-runner/run.ts: testing",
"src/agents/embedded-agent-runner/runs.ts: testing",
"src/agents/embedded-agent-runner/session-manager-cache.ts: createSessionManagerCache",
"src/agents/embedded-agent-subscribe.handlers.messages.ts: buildAssistantStreamData",
"src/agents/embedded-agent-subscribe.handlers.messages.ts: recordPendingAssistantReplyDirectives",
"src/agents/embedded-agent-subscribe.handlers.messages.ts: resolveSilentReplyFallbackText",
"src/agents/embedded-agent-subscribe.tools.ts: isToolResultMediaTrusted",
"src/agents/harness/lifecycle-hook-helpers.ts: clearAgentHarnessFinalizeRetryBudget",
"src/agents/mcp-ui-resource.ts: testing",
"src/agents/model-fallback.ts: testing",
"src/agents/modes/interactive/theme/theme.ts: setTheme",
"src/agents/openai-completions-compat.ts: resolveOpenAICompletionsCompatDefaults",
"src/agents/openai-transport-stream.ts: testing",
"src/agents/session-model-auto-revert.ts: reconcileAgentPatchedSessionModel",
"src/agents/session-suspension.ts: testing",
"src/agents/sessions/tools/bash.ts: resolveBashTimeoutMs",
"src/agents/tool-search.ts: testing",
"src/agents/tool-search.ts: ToolSearchCatalogSession",
"src/agents/tools/image-generate-tool.ts: resolveImageGenerationModelConfigForTool",
"src/agents/tools/image-tool.ts: resolveImageModelConfigForTool",
"src/agents/tools/image-tool.ts: testing",
"src/agents/tools/model-config.helpers.ts: hasDirectProviderApiKeyAuthForTool",
"src/agents/tools/sessions-resolution.ts: testing",
"src/agents/tools/sessions-send-tool.a2a.ts: testing",
"src/agents/tools/video-generate-tool.ts: resolveVideoGenerationModelConfigForTool",
"src/agents/tools/web-fetch.ts: sanitizeWebFetchUrl",
"src/agents/utils/tools-manager.ts: testing",
"src/auto-reply/reply/abort.ts: testing",
"src/auto-reply/reply/acp-reset-target.ts: testing",
"src/auto-reply/reply/agent-runner-context-recovery.ts: computeContextAwareReserveTokensFloor",
"src/auto-reply/reply/agent-runner-memory.ts: setAgentRunnerMemoryTestDeps",
"src/auto-reply/reply/agent-runner-session-reset.ts: setAgentRunnerSessionResetTestDeps",
"src/auto-reply/reply/commands-login.ts: testing",
"src/auto-reply/reply/dispatch-from-config.ts: testing",
"src/auto-reply/reply/queue/cleanup.ts: testing",
"src/auto-reply/reply/queue/enqueue.ts: resetRecentQueuedMessageIdDedupe",
"src/auto-reply/reply/reply-run-registry.ts: testing",
"src/auto-reply/reply/stage-sandbox-media.ts: testing",
"src/auto-reply/usage-bar/template.ts: clearUsageBarTemplateCacheForTest",
"src/cli/channel-options.ts: testing",
"src/cli/command-secret-gateway.ts: testing",
"src/cli/gateway-cli/run.ts: testing",
"src/cli/plugins-install-command.ts: loadConfigForInstall",
"src/cli/plugins-list-format.ts: formatPluginLine",
"src/cli/startup-metadata.ts: testing",
"src/cli/update-cli/update-command-plugins.ts: buildInvalidConfigPostCoreUpdateResult",
"src/cli/update-cli/update-command-plugins.ts: collectMissingPluginInstallPayloads",
"src/cli/update-cli/update-command-plugins.ts: resolvePostSyncPluginUpdateSkipIds",
"src/cli/update-cli/update-command-service.ts: formatPostUpdateGatewayRecoveryInstructions",
"src/cli/update-cli/update-command-service.ts: recoverInstalledLaunchAgentAfterUpdate",
"src/cli/update-cli/update-command-service.ts: recoverLaunchAgentAndRecheckGatewayHealth",
"src/cli/update-cli/update-command-service.ts: shouldUseLegacyProcessRestartAfterUpdate",
"src/commands/audit.ts: testApi",
"src/commands/backup-shared.ts: resolveBackupPlanFromPaths",
"src/commands/doctor-auth-oauth-sidecar.ts: testing",
"src/commands/doctor-auth.ts: legacyCodexProviderOverrideToHealthFinding",
"src/commands/doctor-heartbeat-main-session-repair.ts: moveHeartbeatMainSessionEntry",
"src/commands/doctor-heartbeat-main-session-repair.ts: resolveHeartbeatMainSessionRepairCandidate",
"src/commands/doctor-sandbox.ts: resolveSandboxScript",
"src/commands/doctor-session-snapshots.ts: resolveSessionSnapshotBundledSkillsDir",
"src/commands/doctor-session-snapshots.ts: scanSessionStoreForStaleRuntimeSnapshotPaths",
"src/commands/doctor-whatsapp-responsiveness.ts: listLocalTuiProcesses",
"src/commands/doctor-whatsapp-responsiveness.ts: terminateLocalTuiProcesses",
"src/commands/doctor/shared/codex-native-assets.ts: scanCodexNativeAssets",
"src/commands/doctor/shared/codex-route-warnings.ts: repairCodexSessionStoreRoutes",
"src/commands/doctor/shared/legacy-oauth-sidecar.ts: legacyOAuthSidecarInternalTestUtils",
"src/commands/doctor/shared/plugin-dependency-cleanup.ts: testing",
"src/commands/doctor/shared/stale-auth-order.ts: repairStaleConfiguredAuthOrders",
"src/commands/doctor/shared/stale-oauth-profile-shadows.ts: testing",
"src/commands/onboard-inference.ts: detectNativeCodexAppServer",
"src/commands/onboard-non-interactive/local.ts: resolveGatewayHealthProbeToken",
"src/commands/onboard-non-interactive/local.ts: resolveInstallDaemonGatewayHealthTiming",
"src/commands/onboard-skills.ts: testing",
"src/commands/onboarding-plugin-install.ts: testing",
"src/commands/sessions-tail.ts: setSessionsTailFollowIntervalMsForTests",
"src/commands/sessions.ts: testing",
"src/commands/status.command.ts: resolvePairingRecoveryContext",
"src/commitments/extraction.ts: validateCommitmentCandidates",
"src/commitments/runtime.ts: configureCommitmentExtractionRuntime",
"src/commitments/runtime.ts: drainCommitmentExtractionQueue",
"src/commitments/runtime.ts: resetCommitmentExtractionRuntimeForTests",
"src/cron/isolated-agent/delivery-dispatch.ts: getCompletedDirectCronDeliveriesCountForTests",
"src/cron/isolated-agent/delivery-dispatch.ts: resetCompletedDirectCronDeliveriesForTests",
"src/cron/schedule.ts: clearCronScheduleCacheForTest",
"src/cron/schedule.ts: getCronScheduleCacheMaxForTest",
"src/cron/schedule.ts: getCronScheduleCacheSizeForTest",
"src/cron/schedule.ts: hasCronInCacheForTest",
"src/cron/service/active-run-cancellation.ts: cancelActiveCronTaskRun",
"src/cron/service/active-run-cancellation.ts: resetActiveCronTaskRunsForTests",
"src/cron/service/timer.ts: executeJobCore",
"src/cron/service/timer.ts: onTimer",
"src/cron/session-reaper.ts: resetReaperThrottle",
"src/entry.compile-cache.ts: buildOpenClawCompileCacheRespawnPlan",
"src/entry.compile-cache.ts: isNodeVersionAffectedByCompileCacheDeadlock",
"src/entry.compile-cache.ts: isSourceCheckoutInstallRoot",
"src/entry.compile-cache.ts: resolveOpenClawCompileCacheDirectory",
"src/entry.compile-cache.ts: runOpenClawCompileCacheRespawnPlan",
"src/entry.compile-cache.ts: shouldEnableOpenClawCompileCache",
"src/flows/doctor-health-contributions.ts: createDoctorHealthContribution",
"src/flows/doctor-health-contributions.ts: resolveDoctorHealthContributions",
"src/logging/diagnostic-run-activity.ts: markDiagnosticModelStartedForTest",
"src/logging/diagnostic-run-activity.ts: markDiagnosticRunProgressForTest",
"src/logging/diagnostic-run-activity.ts: markDiagnosticToolStartedForTest",
"src/logging/redact-internal.ts: withFullContextToolPayloadRedaction",
"src/logging/secret-redaction-registry.ts: resetSecretRedactionRegistryForTest",
"src/node-host/invoke.ts: testing",
"src/plugin-state/plugin-state-store.sqlite.ts: probePluginStateStore",
"src/plugin-state/plugin-state-store.sqlite.ts: seedPluginStateDatabaseEntriesForTests",
"src/plugin-state/plugin-state-store.sqlite.ts: setMaxPluginStateEntriesPerPluginForTests",
"src/plugin-state/plugin-state-store.ts: clearPluginStateStoreForTests",
"src/sessions/session-lifecycle-admission.ts: runExclusiveSessionLifecycle",
"src/sessions/session-upstream-monitor.ts: runSessionUpstreamMonitorTick",
"src/sessions/user-turn-transcript.ts: persistUserTurnTranscript",
"src/skills/lifecycle/install.ts: testing",
"src/skills/lifecycle/upload-store.ts: createSkillUploadStore",
"src/skills/runtime/refresh.ts: resetSkillsRefreshForTest",
"src/skills/runtime/remote-skills.ts: resetRemoteNodeSkillsForTests",
"src/system-agent/agent-turn.ts: runSystemAgentTurnWithDeps",
"src/tasks/detached-task-runtime.ts: resetDetachedTaskLifecycleRuntimeForTests",
"src/tasks/detached-task-runtime.ts: setDetachedTaskLifecycleRuntime",
"src/tasks/generated-media-task-activity.ts: resetGeneratedMediaTaskActivityForTests",
"src/tasks/task-flow-registry.store.ts: configureTaskFlowRegistryRuntime",
"src/tasks/task-flow-registry.ts: createFlowRecord",
"src/tasks/task-flow-registry.ts: resetTaskFlowRegistryForTests",
"src/tasks/task-registry.ts: maybeDeliverTaskStateChangeUpdate",
"src/tasks/task-registry.ts: resetTaskRegistryControlRuntimeForTests",
"src/tasks/task-registry.ts: resetTaskRegistryDeliveryRuntimeForTests",
"src/tasks/task-registry.ts: resetTaskRegistryForTests",
"src/tasks/task-registry.ts: setTaskRegistryControlRuntimeForTests",
"src/tasks/task-registry.ts: setTaskRegistryDeliveryRuntimeForTests",
];
// Platform-variant findings. Allowed when present; never required.
export const KNIP_OPTIONAL_UNUSED_EXPORT_BASELINE = [];