Files
BalanceServer/.github/workflows/ci.yml
T
wtandClaude Opus 5.5 10272f3851
CI / Rust (fmt / clippy / test / build) (push) Successful in 1m41s
CI / HTTP/JSON reference + SQLite persistence (push) Successful in 1m16s
CI / Rust (fmt / clippy / test / build) (pull_request) Successful in 47s
CI / HTTP/JSON reference + SQLite persistence (pull_request) Successful in 1m34s
Remove the Go reference server; keep only Rust
The Go implementation is preserved in the v1.0.0 tag. Its observable
behaviour stays the API reference: responses recorded from the Go server
live in tools/compatibility_expected.txt, and tools/compatibility.py now
compares the Rust server against them (--update re-records after an
intentional change). The Go SQLite schema is frozen in
tests/fixtures/go_schema_v1.sql for the existing-database test.

Move the web client from internal/httpapi/web to web/, drop the Go CI job
and Go version pin, and update README, AGENTS.md and docs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-30 16:27:33 +07:00

91 lines
2.2 KiB
YAML

name: CI
on:
push:
branches: [main, master, develop]
pull_request:
env:
CARGO_TERM_COLOR: always
# Pin the toolchain to the declared MSRV so CI matches production.
RUST_TOOLCHAIN: 1.90.0
jobs:
rust:
name: Rust (fmt / clippy / test / build)
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
toolchain: ${{ env.RUST_TOOLCHAIN }}
components: rustfmt, clippy
- name: Cache Cargo registry and build
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-
- name: Format check
run: cargo fmt --check
- name: Test
run: cargo test --locked
- name: Clippy
run: cargo clippy --locked --all-targets -- -D warnings
- name: Release build
run: cargo build --locked --release
- name: Upload release binary
uses: actions/upload-artifact@v4
with:
name: balance-server-release
path: target/release/balance-server
if-no-files-found: error
compatibility:
name: HTTP/JSON reference + SQLite persistence
runs-on: ubuntu-latest
needs: [rust]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
toolchain: ${{ env.RUST_TOOLCHAIN }}
- name: Install Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Cache Cargo registry and build
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-
- name: Build Rust (debug)
run: cargo build --locked
- name: Compare against the recorded Go reference
run: python3 tools/compatibility.py --binary target/debug/balance-server