Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions config/scripts/check-runtime-electron-ratchet.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ export const STRUCTURED_CHAT_LANES = [
{ directory: ['src', 'main', 'codex'] },
{ directory: ['src', 'shared'] },
{ directory: ['src', 'main', 'runtime'], basename: /^(?:structured-|agent-session-)/ },
// Allowed absent until they land; every other lane throws if missing, so a rename can't empty it.
{ directory: ['src', 'main', 'acp'], mayBeAbsent: true },
{ directory: ['src', 'main', 'provider-process'], mayBeAbsent: true }
{ directory: ['src', 'main', 'provider-process'] },
// Allowed absent until it lands; every other lane throws if missing, so a rename can't empty it.
{ directory: ['src', 'main', 'acp'], mayBeAbsent: true }
]

export function collectStructuredChatEntryPoints(root = ROOT) {
Expand Down
7 changes: 4 additions & 3 deletions config/scripts/check-runtime-electron-ratchet.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,13 @@ describe('structured chat coverage', () => {
return root
}

// Every lane that must exist; acp/ and provider-process/ may be absent until they land.
// Every lane that must exist; acp/ may be absent until it lands.
const requiredLanes = {
'src/main/native-chat/reader.ts': 'export {}',
'src/main/claude/claude-session.ts': 'export {}',
'src/main/codex/codex-session.ts': 'export {}',
'src/main/runtime/structured-agent-session-host.ts': 'export {}',
'src/main/provider-process/provider-process-teardown.ts': 'export {}',
'src/shared/agent-session-record.ts': 'export {}'
}

Expand Down Expand Up @@ -89,7 +90,7 @@ describe('structured chat coverage', () => {
Object.entries(requiredLanes).filter(([file]) => !file.startsWith(`${lane}/`))
)
expect(() => collectStructuredChatEntryPoints(fixture(without))).toThrow(`${lane} is missing`)
expect(collectStructuredChatEntryPoints(fixture(requiredLanes))).toHaveLength(5)
expect(collectStructuredChatEntryPoints(fixture(requiredLanes))).toHaveLength(6)
}
)

Expand Down Expand Up @@ -128,7 +129,7 @@ describe('the default entry points', () => {
}
})

// Retires the temporary flag: the PR that adds acp/ or provider-process/ must make it required.
// Retires the temporary flag: the PR that adds acp/ must make it required.
it('lets only directories that have not landed yet be absent', () => {
for (const lane of STRUCTURED_CHAT_LANES.filter((candidate) => candidate.mayBeAbsent)) {
expect(
Expand Down
Loading