mirror of
https://github.com/fancive/obsidian-parallel-reader.git
synced 2026-07-22 06:53:43 +00:00
Claude CLI 2.1.131+ rejects `--output-format stream-json` unless `--verbose` is also passed. Without it the CLI exits 1 with "When using --print, --output-format=stream-json requires --verbose", breaking the Claude Code backend. Adds the flag in src/cli.ts and locks both the flag and full args contract for Claude + Codex backends with new tests: - testClaudeCodeArgs: extended with mcp-config / disallowed-tools / chrome / slash-commands assertions and --verbose position check - testClaudeCodeStreamJsonResilience: banner-mixed NDJSON, missing result, empty stdout, multiple result events, content fallback - testClaudeCodeVerboseRegressionCanary: simulates real CLI stderr on missing --verbose and asserts error pipeline preserves exitCode + stderr - testCodexErrorPath: codex non-zero exit propagates structured error - testCodexArgsMinimalContract: deepStrictEqual lock on codex args 5-tuple - testClaudeBackendSurfacesVerboseError: smoke flow surfaces the canary - testCodexBackendPropagatesVersionFailure: version probe failure blocks smoke instead of silently continuing Also wires npm run lint:obsidian into CI alongside Biome. Closes #3 Change-Id: I6dbaa1b55172eb0b5b773bd25d1741b0603a4e4e
41 lines
785 B
YAML
41 lines
785 B
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 22
|
|
cache: npm
|
|
|
|
- run: npm ci
|
|
|
|
- name: Lint
|
|
run: npm run lint
|
|
|
|
- name: Lint (Obsidian review rules)
|
|
run: npm run lint:obsidian
|
|
|
|
- name: E2E gate
|
|
run: timeout 600 npm run e2e
|
|
|
|
- name: Upload e2e artifacts on failure
|
|
if: failure()
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: e2e-${{ github.run_id }}
|
|
if-no-files-found: ignore
|
|
path: |
|
|
.e2e/artifact.json
|
|
.e2e/results/
|