Skip to content

chore: enforce nightly formatting#407

Open
Vaiz wants to merge 4 commits intomainfrom
nightly-rustfmt-ci
Open

chore: enforce nightly formatting#407
Vaiz wants to merge 4 commits intomainfrom
nightly-rustfmt-ci

Conversation

@Vaiz
Copy link
Copy Markdown
Contributor

@Vaiz Vaiz commented May 7, 2026

No description provided.

Vaiz and others added 2 commits May 7, 2026 11:36
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 7, 2026 10:46
@Vaiz Vaiz enabled auto-merge (squash) May 7, 2026 10:49
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the repository’s formatting checks to use nightly rustfmt with the repo’s unstable-rustfmt.toml, and applies the resulting formatting/import-order changes across multiple crates and documentation examples.

Changes:

  • Run format checks with nightly rustfmt using --config-path ./unstable-rustfmt.toml (local just + CI).
  • Update GitHub Actions to install nightly rustfmt and run formatting under the nightly toolchain.
  • Apply consistent rustfmt-driven formatting/import grouping updates across source, tests, examples, and doc snippets.

Reviewed changes

Copilot reviewed 37 out of 39 changed files in this pull request and generated no comments.

Show a summary per file
File Description
justfiles/format.just Switches just format / format-check to nightly rustfmt with --config-path unstable-rustfmt.toml.
.github/workflows/main.yml Installs nightly rustfmt and runs cargo +nightly fmt using the unstable rustfmt config; removes stable rustfmt component from setup.
crates/templated_uri/src/uri.rs Doc snippet import ordering / formatting updates.
crates/templated_uri/src/path_and_query_template.rs Doc snippet import ordering updates.
crates/templated_uri/src/lib.rs Reorders public re-exports and doc snippet import order (format-driven).
crates/templated_uri/src/base_uri.rs Doc snippet formatting (line wrapping / indentation).
crates/templated_uri/src/_documentation/recipes.rs Doc example formatting and import ordering.
crates/templated_uri/examples/classified_templating.rs Import grouping/order changes.
crates/seatbelt/src/retry/mod.rs Moves deprecated re-export to satisfy formatting/order.
crates/seatbelt/src/hedging/telemetry.rs Import consolidation and test module import ordering.
crates/seatbelt/src/hedging/service.rs Minor whitespace alignment in tests.
crates/seatbelt/src/hedging/mod.rs Moves deprecated re-export to satisfy formatting/order.
crates/seatbelt/src/hedging/layer.rs Consolidates constants imports.
crates/seatbelt/src/hedging/args.rs Import ordering adjustment.
crates/seatbelt/src/fallback/mod.rs Doc snippet formatting (one-line closure).
crates/seatbelt/src/fallback/layer.rs Import grouping/order adjustment.
crates/seatbelt/src/context.rs Import ordering/grouping adjustment.
crates/seatbelt/src/chaos/latency/mod.rs Doc snippet formatting (method chain in one line).
crates/seatbelt/examples/retry_advanced.rs Import grouping/order adjustment.
crates/recoverable/src/io.rs Test import ordering adjustment.
crates/recoverable/src/_documentation/recipes.rs Doc snippet formatting (multiline args).
crates/ohno/src/lib.rs Re-export ordering adjustment.
crates/ohno/src/error_label.rs Test import ordering adjustment.
crates/http_extensions/src/http_response_builder.rs Doc snippet formatting (method chain wrapping).
crates/http_extensions/src/http_request_builder.rs Doc snippet formatting (async chain wrapping).
crates/http_extensions/src/fake_handler.rs Doc snippet indentation alignment.
crates/http_extensions/src/extensions/request_ext.rs Import ordering adjustment.
crates/http_extensions/src/error.rs Doc snippet indentation alignment.
crates/http_extensions/src/body/options.rs Doc snippet formatting (method chain).
crates/http_extensions/src/body/builder.rs Import ordering and test module import ordering.
crates/http_extensions/src/_documentation/recipes.rs Doc snippet import ordering and formatting (wrapping).
crates/cachet/src/transform/tier.rs Import ordering and test import ordering.
crates/cachet/src/transform/codec.rs Doc snippet import ordering.
crates/cachet/src/policy.rs Doc snippet formatting (closure wrapping).
crates/cachet/src/fallback.rs Consolidates imports in tests.
crates/cachet_tier/src/dynamic.rs Import ordering/grouping adjustment.
crates/cachet_memory/src/tier.rs Import ordering adjustment.
crates/cachet_memory/src/builder.rs Doc snippet import splitting/order.
crates/anyspawn/src/spawner.rs Import consolidation and doc snippet formatting/wrapping.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.0%. Comparing base (3b9dd96) to head (ff373a6).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #407   +/-   ##
=======================================
  Coverage   100.0%   100.0%           
=======================================
  Files         227      227           
  Lines       16740    16740           
=======================================
  Hits        16740    16740           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@geeknoid
Copy link
Copy Markdown
Member

geeknoid commented May 7, 2026

I don't think this is a good idea. It means that it would require devs to have nightly bits installed in order to be able to reliably make changes for this repo.

@Vaiz
Copy link
Copy Markdown
Contributor Author

Vaiz commented May 7, 2026

I don't think this is a good idea. It means that it would require devs to have nightly bits installed in order to be able to reliably make changes for this repo.

we need to enforce this if we want to avoid PRs with hundreds changed files just because developer applied nightly formatting on the whole repo

@Vaiz Vaiz disabled auto-merge May 7, 2026 12:52
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 7, 2026 12:56
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 26 out of 26 changed files in this pull request and generated no new comments.

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.

5 participants