Skip to content

ci(workspace): add strict clippy checks to selected handwritten crates#5635

Open
suzmue wants to merge 1 commit intogoogleapis:mainfrom
suzmue:linters-doc
Open

ci(workspace): add strict clippy checks to selected handwritten crates#5635
suzmue wants to merge 1 commit intogoogleapis:mainfrom
suzmue:linters-doc

Conversation

@suzmue
Copy link
Copy Markdown
Contributor

@suzmue suzmue commented May 8, 2026

Add a strict clippy check to the GCB lint.sh and lint-unstable.sh scripts that runs with --no-deps on a targeted set of handwritten client libraries in non-test mode.

The strict clippy run checks for missing_docs and clippy::exhaustive_enums on: auth, bigquery, bigtable, datastore, firestore, gax, lro, pubsub, storage, and wkt.

To prepare the target crates for these checks, this commit:

  • Documents the src/auth/build.rs build script to resolve missing_docs.
  • Adds #[allow(clippy::exhaustive_enums)] to stable public and internal enums across the target crates to avoid public API breaking changes.

@suzmue suzmue requested review from a team as code owners May 8, 2026 19:41
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces stricter linting for handwritten crates by adding checks for missing documentation and non-exhaustive enums in the CI scripts. To accommodate these changes, documentation was added to the auth build script, and several enums across the workspace were annotated with #[allow(clippy::exhaustive_enums)]. The reviewer recommends adding the --all-features flag to the new clippy commands in the GCB scripts to ensure that public items and enums located behind feature gates are also validated.

Comment thread .gcb/scripts/lint-unstable.sh Outdated
Comment thread .gcb/scripts/lint.sh Outdated
@codecov
Copy link
Copy Markdown

codecov Bot commented May 8, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.76%. Comparing base (02edf0b) to head (ade8812).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5635   +/-   ##
=======================================
  Coverage   97.76%   97.76%           
=======================================
  Files         221      221           
  Lines       51115    51115           
=======================================
+ Hits        49971    49972    +1     
+ Misses       1144     1143    -1     

☔ 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.

Add a strict clippy check to the GCB `lint.sh` and `lint-unstable.sh` scripts
that runs with `--no-deps` on a targeted set of handwritten client libraries
in non-test mode.

The strict clippy run checks for `missing_docs` and `clippy::exhaustive_enums`
on: `auth`, `bigquery`, `bigtable`, `datastore`, `firestore`, `gax`, `lro`,
`pubsub`, `storage`, and `wkt`.

To prepare the target crates for these checks, this commit:
- Documents the `src/auth/build.rs` build script to resolve `missing_docs`.
- Adds `#[allow(clippy::exhaustive_enums)]` to stable public and internal
  enums across the target crates to avoid public API breaking changes.
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.

3 participants