Skip to content

Rewrite backend in Rust with embedded frontend (v0.0.2) - #34

Merged
andrewchen5678 merged 6 commits into
mainfrom
rust-rewrite
Sep 25, 2026
Merged

andrewchen5678 merged 6 commits into
mainfrom
rust-rewrite

Conversation

@andrewchen5678

Copy link
Copy Markdown
Contributor

Summary

  • Replace the Python backend with a single Rust binary (axum + sqlx + aws-sdk-s3) with server and index subcommands; release builds embed the React frontend.
  • Unit tests plus an end-to-end suite against Silo S3 + Postgres (scripts/e2e.sh), wired into CI.
  • Hardening: safe_next rejects /\ and control characters, schema bootstrap takes an advisory lock, indexer skips soft-delete when sidecar fetches fail or no stations are found.
  • Release workflow (like minisearch): builds binaries once, publishes them, and builds images from the prebuilt binary; runs are serialized and the tag targets the built commit.
  • Version bumped to 0.0.2.

Test plan

  • cargo clippy --all-targets -- -D warnings, cargo test
  • ./scripts/e2e.sh (9 e2e tests)
  • bun run lint, bun run typecheck in frontend/

🤖 Generated with Claude Code

Andrew Chen and others added 6 commits September 24, 2026 17:34
Replace the FastAPI backend with a single axum binary (sqlx + aws-sdk-s3),
modeled on minisearch: release builds embed the Vite frontend via build.rs,
the Dockerfile and release workflow build binaries plus ghcr images, and CI
runs clippy, cargo test, and the frontend checks.

Same env vars, schema, and API responses. S3 requests use path-style
addressing; OpenAPI docs are replaced by an API table in
docs/architecture.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Unit tests for S3 pagination/fetch, indexer station discovery and
  sidecar decoding, audio proxy status/header mapping and presigning,
  DB settings resolution, CLI parsing, auth and error rendering.
- tests/e2e.rs runs the real binary (index and server) against Silo S3
  and Postgres; scripts/e2e.sh provisions both and supports --coverage.
- CI job for the e2e suite.
- Fix: map the SDK's "NotFound" code (bodyless 404) to 404 in the audio
  proxy and treat it as empty in chapter summaries.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…soft-delete

- Serialize release runs, tag the built commit, and create the release only
  after the multi-arch manifests are pushed.
- README: commit Cargo.lock with the version bump.
- safe_next rejects `/\` prefixes and control characters.
- Schema bootstrap holds a transaction-scoped advisory lock.
- Indexer counts sidecar fetch failures separately and skips soft-delete when
  any fetch failed or no stations were found.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…nisearch

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@andrewchen5678
andrewchen5678 merged commit 31f1d89 into main Sep 25, 2026
3 checks passed
@andrewchen5678
andrewchen5678 deleted the rust-rewrite branch September 25, 2026 01:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant