mirror of
https://github.com/morluto/rea.git
synced 2026-12-03 05:07:49 +00:00
test(clients): check configured MCP catalogs in native harnesses (#15121)
* test(clients): check configured MCP catalogs in native harnesses * test(opencode): resolve the native CLI in the isolated home * ci(clients): identify native catalog discovery in the job log * test(ci): isolate native clients and preserve registration failures
This commit is contained in:
1 parent
7025845302
commit
8e18bdecef
11 files changed
+530
-43
No files matched your search
@@ -0,0 +1,78 @@
|
||||
name: Native MCP registration
|
||||
on:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: "31 8 * * 2"
|
||||
pull_request:
|
||||
paths:
|
||||
- ".github/workflows/real-client-registration.yml"
|
||||
- ".nvmrc"
|
||||
- "package*.json"
|
||||
- "scripts/rea.mjs"
|
||||
- "scripts/verify-*-client.mjs"
|
||||
- "scripts/verify/clients/**"
|
||||
- "scripts/lib/**"
|
||||
- "src/application/*Client*.ts"
|
||||
- "src/application/Setup*.ts"
|
||||
- "src/cli/**"
|
||||
- "src/composition/**"
|
||||
- "src/config/**"
|
||||
- "src/contracts/**"
|
||||
- "src/server/**"
|
||||
- "!src/**/*.test.ts"
|
||||
permissions:
|
||||
contents: read
|
||||
jobs:
|
||||
scoped-catalog:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 12
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- client: codex
|
||||
package: "@openai/codex"
|
||||
version: "0.172.0"
|
||||
- client: claude
|
||||
package: "@anthropic-ai/claude-code"
|
||||
version: "2.1.332"
|
||||
- client: gemini
|
||||
package: "@google/gemini-cli"
|
||||
version: "0.70.0"
|
||||
- client: opencode
|
||||
package: "opencode-ai"
|
||||
version: "1.19.6"
|
||||
steps:
|
||||
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
|
||||
with:
|
||||
persist-credentials: false
|
||||
- name: Verify the catalog in an isolated native client
|
||||
env:
|
||||
CLIENT: ${{ matrix.client }}
|
||||
CLIENT_PACKAGE: ${{ matrix.package }}
|
||||
CLIENT_VERSION: ${{ github.event_name == 'schedule' && 'latest' || matrix.version }}
|
||||
run: |
|
||||
# Only tracked source and these three inputs enter the container.
|
||||
git archive HEAD | docker run -i --name native-client --user node \
|
||||
-e CLIENT -e CLIENT_PACKAGE -e CLIENT_VERSION \
|
||||
-e REA_VERIFY_CODEX_FAILURE_PATH=/tmp/codex-registration-failure.json \
|
||||
"node:$(cat .nvmrc)-bookworm" bash -eu -o pipefail -c '
|
||||
cd "$(mktemp -d)"
|
||||
tar -xf -
|
||||
npm ci
|
||||
npm install --prefix /tmp/native-client --no-package-lock --no-audit --no-fund "$CLIENT_PACKAGE@$CLIENT_VERSION"
|
||||
PATH="/tmp/native-client/node_modules/.bin:$PATH" npm run "verify:${CLIENT}-client" -- scoped-chat
|
||||
'
|
||||
- name: Recover Codex failure report
|
||||
if: failure() && matrix.client == 'codex'
|
||||
id: diagnostics
|
||||
run: |
|
||||
report="$RUNNER_TEMP/codex-registration-failure.json"
|
||||
if docker cp native-client:/tmp/codex-registration-failure.json "$report" && [[ -f "$report" && ! -L "$report" ]]; then
|
||||
echo 'available=true' >> "$GITHUB_OUTPUT"
|
||||
fi
|
||||
- uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
|
||||
if: failure() && steps.diagnostics.outputs.available == 'true'
|
||||
with:
|
||||
name: codex-registration-failure
|
||||
path: ${{ runner.temp }}/codex-registration-failure.json
|
||||
Reference in new issue
Block a user