Skip to content

Add an MSRV + stable toolchain matrix to CI #8

Open

Description

@francescobianco

Description

CI builds only with the toolchain preinstalled on ubuntu-latest. Once the crate declares a rust-version (see #4), nothing ensures it still builds with that version. A dependency bump or a newer language feature could silently break it.

Proposal

Extend .github/workflows/rust.yml with a toolchain matrix, for example using dtolnay/rust-toolchain:

  • stable: build + test (what we have today)
  • MSRV: cargo build --locked with the version from rust-version, ideally read from Cargo.toml rather than hard-coded
  • optionally beta, non-blocking, as an early warning

Also add Swatinem/rust-cache to keep CI fast.

Benefits

  • ✅ The declared MSRV is a guarantee, not a hope
  • ✅ --locked ensures CI uses exactly the committed Cargo.lock
  • ✅ Faster CI thanks to caching

Acceptance criteria

  • CI has a stable job and an MSRV job, both green
  • The MSRV job uses --locked
  • The MSRV version comes from a single source of truth

Depends on #4 being merged first, but you can start in parallel.

Context

This is part of bringing openapi-cli up to the same baseline the Openapi® Rust SDK just reached with its move to the Rust 2024 edition (openapi-rust-sdk#14, announced in discussions#86). The CLI already uses edition = "2024"; these issues make it hold up in practice.

New here?

This is a small, self-contained task: a great first contribution to an Openapi® project. Comment below to claim it, then fork, branch and open a PR referencing this issue. Questions are welcome in the thread. Once merged, you are welcome to add yourself to the official Openapi® contributors registry. 🦀

Activity

  1. added
    enhancement
    good first issue
    help wanted
    on Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementgood first issuehelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions