Skip to content

Commit 1334a97

Browse files
committed
chore: delete five verified-dead artifacts
A no-op flag parsing clause with its fixture, a stop-policy shim whose sole caller is a newer parameter, two settings that nothing reads, the stub workflows package, and a Codex refresh constant with an unused re-export in this repo. Every item carries repo-wide zero-caller evidence at deletion time; the dead-export gate's allowlist shrank by the same two entries and re-verifies by failing on stale rows. Live artifacts (sessionMode machinery, .agent-state dual-read, scripts, bin/) stay as they are.
1 parent 1fa3f89 commit 1334a97

13 files changed

Lines changed: 10 additions & 99 deletions

File tree

‎bun.lock‎

Lines changed: 0 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎scripts/check-dead-exports.test.ts‎

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -46,18 +46,7 @@ describe("scoped exemptions", () => {
4646
test("the real allowlist covers the named flags but not a sibling probe", () => {
4747
const rules = loadAllowlist();
4848
expect(
49-
isAllowlisted(
50-
rules,
51-
"src/auth/codex/constants.ts",
52-
"CODEX_REFRESH_SKEW_MS",
53-
),
54-
).toBe(true);
55-
expect(
56-
isAllowlisted(
57-
rules,
58-
"src/auth/codex/constants.ts",
59-
"CODEX_HEADLESS_REFRESH_INTERVAL_MS",
60-
),
49+
isAllowlisted(rules, "src/provider/reasoning-effort.ts", "satisfies"),
6150
).toBe(true);
6251
expect(
6352
isAllowlisted(rules, "src/auth/codex/usage.ts", "someNewDeadExport"),

‎scripts/dead-export-allowlist.txt‎

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,6 @@
2020
# vendor workspaces on the next sync. Prune upstream, not here.
2121
vendor/
2222

23-
# Deferred Codex/xAI usage-data cleanup owned by the CL-6815 lane: these
24-
# modules are fully dead deferred code with no live importers (not test-only
25-
# helpers), and that lane decides their fate. Scoped to the exact ts-prune
26-
# flags so a new dead export in these files fails the guard instead of
27-
# hiding under a whole-file exemption. Remove each entry with the export it
28-
# names when the owning cleanup lands.
29-
src/auth/codex/constants.ts: CODEX_REFRESH_SKEW_MS
30-
src/auth/codex/constants.ts: CODEX_HEADLESS_REFRESH_INTERVAL_MS
31-
3223
# ts-prune parser false positives: bare tokens on `as const satisfies ...`
3324
# lines inside live exports. None of these is an export declaration.
3425
src/provider/reasoning-effort.ts: satisfies

‎src/auth/codex/constants.ts‎

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import { codexOAuthConfig } from "@corbits/codex-provider";
44
export {
55
CODEX_BASE_URL,
66
CODEX_REDIRECT_URI,
7-
CODEX_REFRESH_SKEW_MS,
87
CODEX_RESPONSES_PATH,
98
} from "@corbits/codex-provider";
109

@@ -38,7 +37,3 @@ export const CODEX_DEFAULT_MODELS = [
3837
"gpt-5.6-luna",
3938
"gpt-5.4-mini",
4039
] as const;
41-
42-
// How often a headless run re-checks its Codex token and reseeds the source.
43-
// Half the skew so the refresh window is never missed between ticks.
44-
export const CODEX_HEADLESS_REFRESH_INTERVAL_MS = 30_000;

‎src/config.test.ts‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1744,12 +1744,10 @@ describe("buildProviderCatalog", () => {
17441744
web: "exa",
17451745
hiddenCommands: ["help"],
17461746
onboarded: true,
1747-
compactionMode: "pruning",
17481747
sessionMode: "orchestrator",
17491748
agentModelFallback: "none",
17501749
shell: { timeoutMs: 30_000, maxTimeoutMs: 120_000 },
17511750
tools: { timeoutMs: 60_000 },
1752-
workflowProfiles: { fast: { implement: "fp-large" } },
17531751
};
17541752
const settings = providerCatalogToSettings(
17551753
[

‎src/config/index.ts‎

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -662,8 +662,6 @@ export interface Config {
662662
*/
663663
modelOverride?: boolean;
664664

665-
// Deprecated no-op retained for CLI compatibility.
666-
noWorkflow: boolean;
667665
/**
668666
* Runtime settings view for provider resolution, including OAuth
669667
* projections never written to settings.json. Not for saveGlobalSettings —
@@ -887,7 +885,6 @@ export async function loadConfig(
887885
let provider: string | undefined;
888886
let model: string | undefined;
889887
let profileFlag: string | undefined;
890-
let noWorkflow = false;
891888
const positional: string[] = [];
892889

893890
const requireValue = (flag: string, value: string | undefined): string => {
@@ -949,10 +946,6 @@ export async function loadConfig(
949946
auto = false;
950947
continue;
951948
}
952-
if (arg === "--no-workflow") {
953-
noWorkflow = true;
954-
continue;
955-
}
956949
if (arg === "-p") {
957950
command = "exec";
958951
continue;
@@ -1216,7 +1209,6 @@ export async function loadConfig(
12161209
...(director !== undefined ? { director } : {}),
12171210
globalSettingsPath: effectiveSettingsPath,
12181211
sessionId,
1219-
noWorkflow,
12201212
...(resumeMode !== undefined
12211213
? {
12221214
resumeMode,

‎src/config/settings.test.ts‎

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -202,21 +202,6 @@ test("loadConfig --no-auto disables auto mode", async () => {
202202
});
203203
});
204204

205-
test("loadConfig --no-workflow remains a recognized flag", async () => {
206-
await withSettings(async ({ cwd, globalSettingsPath }) => {
207-
const { impl } = offlineFetch();
208-
const config = await loadConfig(
209-
["--cwd", cwd, "--no-workflow", "do something"],
210-
{
211-
globalSettingsPath,
212-
pricing: { fetchImpl: impl },
213-
},
214-
);
215-
expect(config.configured).toBe(true);
216-
if (config.configured) expect(config.noWorkflow).toBe(true);
217-
});
218-
});
219-
220205
test("loadConfig uses the injected pricing fetchImpl instead of the network", async () => {
221206
await withSettings(async ({ cwd, globalSettingsPath }) => {
222207
resetPricingMetadataRefreshForTests();
@@ -419,7 +404,6 @@ test("loadSettings cannot silently drop a known optional key", async () => {
419404
defaultProvider: "p",
420405
mcpServers: [{ name: "s", command: "echo" }],
421406
tiers: { fast: { provider: "p", model: "m" } },
422-
workflowProfiles: { default: { implement: "m" } },
423407
plugins: { "plug-a": { enabled: true } },
424408
pluginPaths: ["/tmp/plugin"],
425409
hooks: { "/tmp/hook.ts": { enabled: false } },
@@ -428,7 +412,6 @@ test("loadSettings cannot silently drop a known optional key", async () => {
428412
hiddenCommands: ["/help"],
429413
onboarded: true,
430414
lastChangelogVersion: "0.1.0",
431-
compactionMode: "pruning" as const,
432415
subagentMaxTurns: 20,
433416
sessionMode: "orchestrator" as const,
434417
agentModelFallback: "none" as const,

‎src/config/settings.ts‎

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,6 @@ export interface Settings {
8181
defaultProvider?: string;
8282
providers: Record<string, ProviderSettings>;
8383
mcpServers?: MCPServerSettingsEntry[];
84-
// Per-phase model overrides keyed by profile name, then workflow step
85-
// profile key; a step's `profile` selects the entry.
86-
workflowProfiles?: Record<string, Record<string, string>>;
8784
// Per-plugin config keyed by plugin id: enabled flag plus manifest-declared
8885
// credentials (e.g. an Exa API key). Global-only because it carries secrets;
8986
// the /plugins UI writes it.
@@ -111,9 +108,6 @@ export interface Settings {
111108
// Last package version whose release notes were shown (or stamped on first
112109
// interactive install).
113110
lastChangelogVersion?: string;
114-
// Deprecated: compaction is always the evidence-backed LLM handoff now.
115-
// Legacy values still load but are ignored; new writes omit this field.
116-
compactionMode?: "llm" | "pruning";
117111
// Deprecated: orchestrator is the only product path. Legacy values still
118112
// load but are ignored.
119113
sessionMode?: SessionMode;
@@ -665,7 +659,6 @@ const SettingsSchema = type({
665659
// Model tiers were removed; older files may still carry this key. Accepted
666660
// and ignored so the file loads, then dropped on next save.
667661
"tiers?": "unknown",
668-
"workflowProfiles?": type({ "[string]": type({ "[string]": "string" }) }),
669662
"plugins?": type({
670663
"[string]": type({
671664
"enabled?": "boolean",
@@ -680,7 +673,6 @@ const SettingsSchema = type({
680673
"hiddenCommands?": "string[]",
681674
"onboarded?": "boolean",
682675
"lastChangelogVersion?": "string",
683-
"compactionMode?": "'llm' | 'pruning'",
684676
// Legacy disk values still load; product resolve ignores them.
685677
"sessionMode?": "'single' | 'orchestrator'",
686678

@@ -900,7 +892,6 @@ type OptionalLocalSettingsFields = {
900892
export const GLOBAL_SETTINGS_OPTIONAL_KEYS = [
901893
"defaultProvider",
902894
"mcpServers",
903-
"workflowProfiles",
904895
"plugins",
905896
"pluginPaths",
906897
"hooks",
@@ -909,7 +900,6 @@ export const GLOBAL_SETTINGS_OPTIONAL_KEYS = [
909900
"hiddenCommands",
910901
"onboarded",
911902
"lastChangelogVersion",
912-
"compactionMode",
913903
"sessionMode",
914904
"agentModelFallback",
915905
"shell",
@@ -1098,9 +1088,6 @@ function normalizeParsedSettings(path: string, parsed: unknown): Settings {
10981088
s.mcpServers !== undefined
10991089
? normalizeMcpServers(s.mcpServers)
11001090
: undefined,
1101-
workflowProfiles: s.workflowProfiles as
1102-
| Settings["workflowProfiles"]
1103-
| undefined,
11041091
plugins: s.plugins as Settings["plugins"] | undefined,
11051092
pluginPaths: s.pluginPaths as string[] | undefined,
11061093
hooks: s.hooks as Settings["hooks"] | undefined,
@@ -1113,10 +1100,6 @@ function normalizeParsedSettings(path: string, parsed: unknown): Settings {
11131100
s.lastChangelogVersion.trim().length > 0
11141101
? s.lastChangelogVersion.trim()
11151102
: undefined,
1116-
compactionMode:
1117-
s.compactionMode === "llm" || s.compactionMode === "pruning"
1118-
? s.compactionMode
1119-
: undefined,
11201103
// Drop legacy "single"; keep only explicit orchestrator if present.
11211104
sessionMode: s.sessionMode === "orchestrator" ? "orchestrator" : undefined,
11221105
agentModelFallback:

‎src/session/assemble-runtime.ts‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -551,9 +551,10 @@ export interface ChatAgentWiring {
551551
getSources: () => InferenceSource[];
552552
getDefaultSource: () => string;
553553
/**
554-
* Read at each build so a compaction-mode toggle is visible on rebuild.
555-
* assemble passes the completeness gate as `wrapPruning` so fold-commit
556-
* side effects (stub notice, onFolded prune) run only after a fold lands.
554+
* Read at each build so operator-side compaction changes are visible on
555+
* rebuild. assemble passes the completeness gate as `wrapPruning` so
556+
* fold-commit side effects (stub notice, onFolded prune) run only after a
557+
* fold lands.
557558
*/
558559
getCompactor: (wrapPruning?: (pruning: Compactor) => Compactor) => Compactor;
559560
/**

‎src/subagent/index.test.ts‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,8 @@ describe("sub-agent stop helpers", () => {
347347
evaluateSubAgentStop({
348348
hasToolCalls: false,
349349
lastAssistantText: SUMMARY_ONLY_NARRATION,
350-
incompleteReportNudgeFired: true,
350+
// The nudge bumps the cycle count (nudge-director wraps up here).
351+
toolLessNarrationCycles: 2,
351352
}),
352353
).toBe("incomplete-report-stop");
353354
});
@@ -362,13 +363,12 @@ describe("sub-agent stop helpers", () => {
362363
).toBe("stop");
363364
});
364365

365-
test("evaluateSubAgentStop spiral uses toolLessNarrationCycles over the deprecated flag", () => {
366+
test("evaluateSubAgentStop nudges once on the first tool-less turn, then stops at the cap", () => {
366367
expect(
367368
evaluateSubAgentStop({
368369
hasToolCalls: false,
369370
lastAssistantText: SUMMARY_ONLY_NARRATION,
370371
toolLessNarrationCycles: 1,
371-
incompleteReportNudgeFired: true,
372372
}),
373373
).toBe("incomplete-report");
374374
expect(

0 commit comments

Comments
 (0)