Skip to content

CroCode v0.4.0

Choose a tag to compare

@kacigaya kacigaya released this 02 Nov 18:46
· 15 commits to main since this release

Breaking change: restricted database role

The API and worker now connect with crocode_runtime. This role can read and write data. It cannot change tables. Startup rejects a DATABASE_URL role with superuser, create-database, create-role, or RLS-bypass rights.

Before you upgrade an existing database volume:

  1. Add CROCODE_DB_PASSWORD and MIGRATION_DATABASE_URL to .env.
  2. Follow database setup and upgrades.
  3. Keep the existing database volume.

Compose stops with a clear error until both variables are set.

Agent setup skill

Open the repository in Claude Code or Codex and ask it to set up CroCode. The crocode-setup skill guides the agent through a new install or the database role upgrade above. The agent asks before sudo commands and never shows secrets. See the skill.

Changes

  • Migrations: the new crocode migrate command applies migrations. A Compose migrate service runs it before the API and worker start.
  • Retention: the worker deletes finished reviews after 30 days. It deletes the reviews of deleted installations on the next pass.
  • OSV tools: agents can look up package versions and advisories through api.osv.dev. See configuration.
  • YAML parser: serde-saphyr replaces serde_yaml_ng. This removes the unmaintained unsafe-libyaml (RUSTSEC-2024-0449). The minimum Rust version is now 1.89.
  • Setup: the default GitHub App name is CroCode Bot with a random suffix, because GitHub App names are unique across GitHub. The logo step has a copy button for the badge color and opens the app settings in a new tab.

Validation

  • Rust format and Clippy checks passed. All 55 Rust tests passed, including the database tests on Postgres 17.
  • OSV tool tests passed: 6 of 6.
  • Web lint, type checks, 34 tests, production build, docs build, and docs export passed.
  • Both Compose configurations are valid with .env.example.