Skip to content

Commit 43f27d4

Browse files
committed
ci: add native Windows validation workflow
1 parent 95352ad commit 43f27d4

11 files changed

Lines changed: 1558 additions & 2 deletions
Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
name: Windows CLI Validation
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
fixture_files:
7+
description: Files per generated concurrency fixture
8+
required: false
9+
default: "180"
10+
type: string
11+
12+
permissions:
13+
contents: read
14+
15+
jobs:
16+
validate-windows-x64:
17+
name: Native Windows x64 validation (${{ matrix.os }})
18+
strategy:
19+
fail-fast: false
20+
matrix:
21+
os: [windows-2022, windows-2025]
22+
runs-on: ${{ matrix.os }}
23+
timeout-minutes: 240
24+
steps:
25+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
26+
27+
- uses: msys2/setup-msys2@66cd2cce69caa17b53920067426061ca1de3a884 # v2
28+
with:
29+
msystem: CLANG64
30+
path-type: inherit
31+
install: >-
32+
mingw-w64-clang-x86_64-clang
33+
mingw-w64-clang-x86_64-zlib
34+
mingw-w64-clang-x86_64-python3
35+
make
36+
git
37+
coreutils
38+
zip
39+
40+
- name: Build native production CLI
41+
shell: msys2 {0}
42+
run: scripts/build.sh --with-ui CC=clang CXX=clang++
43+
44+
- name: Verify Windows executable exists
45+
shell: msys2 {0}
46+
run: |
47+
test -s build/c/codebase-memory-cli.exe
48+
build/c/codebase-memory-cli.exe --version
49+
build/c/codebase-memory-cli.exe --help >/dev/null
50+
51+
- name: Run CLI smoke invariants
52+
shell: msys2 {0}
53+
run: |
54+
chmod +x scripts/smoke-invariants.sh
55+
scripts/smoke-invariants.sh build/c/codebase-memory-cli.exe
56+
57+
- name: Run native Windows validation and concurrency evidence
58+
shell: msys2 {0}
59+
env:
60+
PYTHONUTF8: "1"
61+
run: |
62+
mkdir -p validation-evidence
63+
python scripts/evaluate-windows-validation.py \
64+
--binary build/c/codebase-memory-cli.exe \
65+
--output "validation-evidence/windows-validation-${{ matrix.os }}.json" \
66+
--concurrency-output "validation-evidence/concurrency-${{ matrix.os }}.json" \
67+
--fixture-files "${{ inputs.fixture_files }}"
68+
69+
- name: Package validation candidate
70+
if: always()
71+
shell: msys2 {0}
72+
run: |
73+
mkdir -p validation-package
74+
cp build/c/codebase-memory-cli.exe validation-package/ 2>/dev/null || true
75+
cp THIRD_PARTY.md validation-package/ 2>/dev/null || true
76+
cp README.md validation-package/ 2>/dev/null || true
77+
cp validation-evidence/*.json validation-package/ 2>/dev/null || true
78+
(cd validation-package && zip -9 -r "../codebase-memory-cli-windows-x64-${{ matrix.os }}-validation.zip" .)
79+
80+
- name: Upload Windows validation candidate and evidence
81+
if: always()
82+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
83+
with:
84+
name: codebase-memory-cli-windows-x64-${{ matrix.os }}-validation
85+
path: |
86+
codebase-memory-cli-windows-x64-${{ matrix.os }}-validation.zip
87+
validation-evidence/*.json
88+
if-no-files-found: error

‎Makefile.cbm‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ CYPHER_SRCS = src/cypher/cypher.c
300300

301301
# MCP server module (new)
302302
MCP_SRCS = src/mcp/mcp.c src/mcp/index_supervisor.c src/mcp/compact_out.c
303-
OPERATION_SRCS = src/operations/registry.c src/operations/execute.c src/operations/read.c src/operations/coverage.c src/operations/snippet.c src/operations/search.c src/operations/trace.c
303+
OPERATION_SRCS = src/operations/registry.c src/operations/reliability_events.c src/operations/execute.c src/operations/read.c src/operations/coverage.c src/operations/snippet.c src/operations/search.c src/operations/trace.c
304304

305305
# Shared MCP daemon coordination and local transport
306306
DAEMON_SRCS = \
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Consolidated Source Reconciliation — 2026-09-01
2+
3+
This note records the pre-edit reconciliation of the authoritative consolidated archive against the CLI-first engineering handoff.
4+
5+
## Confirmed
6+
7+
- The neutral operation registry contains the six expected reads: `projects`, `status`, `coverage`, `search`, `snippet`, and `trace`.
8+
- Canonical CLI reads execute through `cbm_operation_execute()` locally rather than through MCP.
9+
- Hook augmentation calls neutral operations directly.
10+
- The daemon's legacy tool request path checks the operation registry before falling back to the MCP dispatcher.
11+
- MCP's six migrated read entry points are compatibility adapters to neutral operations; the former authoritative handler bodies are absent.
12+
- The product/build/install surfaces use `codebase-memory-cli`; Windows workflows explicitly validate `codebase-memory-cli.exe`.
13+
- Native Windows x64 uses MSYS2/CLANG64; an experimental Windows ARM64 path is also present.
14+
- `docs/RUNTIME_ASSURANCE_PLAN.md` already records the daemon-authoritative mutation invariant, BUSY/LOCKED-not-corruption rule, doctor/benchmark direction, stable event names, and real-process concurrency scenarios.
15+
16+
## Discrepancies / remaining migration debt
17+
18+
- The daemon wire vocabulary still exposed `REQUEST_MCP` and `REQUEST_TOOL`; neutral operations were reached only as a branch inside `REQUEST_TOOL` and their daemon response was re-wrapped as an MCP text result.
19+
- `main_local_cli_daemon_execute()` is still a legacy-tool path for commands whose behavior has not yet been extracted. This is legitimate transition debt and must not become the neutral operation API.
20+
- Daemon session/context and bootstrap naming still contains MCP concepts (`cbm_mcp_server_t`, MCP tool profiles, MCP client role). These are broader extraction tasks; removing them in the operation-wire checkpoint would mix protocol cleanup with behavior migration.
21+
- Index worker execution still intentionally uses the historical MCP dispatcher until `index_repository` is extracted.
22+
23+
## Checkpoint decision
24+
25+
Introduce a distinct `REQUEST_OPERATION` wire request with canonical operation payloads and no MCP envelope. Keep `REQUEST_MCP` and a separately numbered transitional `REQUEST_TOOL` only for unextracted compatibility behavior. New/extracted daemon callers must use the operation request; legacy tool fallback must not be reachable from it.
26+
27+
The runtime-assurance event vocabulary is also promoted into source as stable identifiers so subsequent coordinator/store instrumentation does not invent incompatible names ad hoc.

0 commit comments

Comments
 (0)