Skip to content

chore(fmt): restore rustfmt on aisix-etcd loader test (post-#362) - #366

Merged
moonming merged 1 commit into
mainfrom
chore/fmt-loader-test
May 21, 2026
Merged

chore(fmt): restore rustfmt on aisix-etcd loader test (post-#362)#366
moonming merged 1 commit into
mainfrom
chore/fmt-loader-test

Conversation

@moonming

Copy link
Copy Markdown
Member

Summary

PR #362 added fn provider_key_happy_path_accepts() with a multi-line vec! initializer that rustfmt collapses to a single line. main has been failing lint (fmt + clippy) on every PR since #362 merged (e.g. ai-gateway#360's run shows the diff at crates/aisix-etcd/src/loader.rs:445).

This is a pure 1-line fmt restore — no logic change.

Verification

  • cargo fmt --all -- --check clean locally on this branch (matches the CI command in .github/workflows/ci.yml).
  • Toolchain: rustc 1.93.1 (pinned via rust-toolchain.toml), rustfmt 1.8.0-stable.

Why a separate PR

Surfaced while debugging CI on ai-gateway#360 (the AISIX-Cloud#410 fix). Keeping this isolated from #360 per surgical-changes discipline — #360 doesn't touch loader.rs.

PR #362 introduced a multi-line vec! initializer in the new
provider_key_happy_path_accepts test that rustfmt collapses to a
single line. main has been failing 'lint (fmt + clippy)' since #362
merged; this restores green.

cargo fmt --all -- --check (matches CI's command) passes after this.
Copilot AI review requested due to automatic review settings May 21, 2026 09:23
@coderabbitai

coderabbitai Bot commented May 21, 2026

Copy link
Copy Markdown

Warning

Rate limit exceeded

@moonming has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 13 minutes and 44 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Free

Run ID: 785eb7c4-4862-4105-b525-f015024be76e

📥 Commits

Reviewing files that changed from the base of the PR and between 8d68d31 and 6b76e09.

📒 Files selected for processing (1)
  • crates/aisix-etcd/src/loader.rs

Note

🎁 Summarized by CodeRabbit Free

Your organization has reached its limit of developer seats under the Pro Plan. For new users, CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please add seats to your subscription by visiting https://app.coderabbit.ai/login.If you believe this is a mistake and have available seats, please assign one to the pull request author through the subscription management page using the link above.

Comment @coderabbitai help to get the list of available commands and usage tips.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Restores rustfmt-compliant formatting in the aisix-etcd loader unit tests to stop cargo fmt --check from failing CI after PR #362 introduced a multi-line vec! initializer that rustfmt collapses.

Changes:

  • Reformat provider_key_happy_path_accepts test to match rustfmt output (no behavioral changes).

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

@moonming
moonming merged commit a3c710e into main May 21, 2026
17 of 18 checks passed
@moonming
moonming deleted the chore/fmt-loader-test branch May 21, 2026 09:36
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.

2 participants