Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: mention that Clippy must be run with the MSRV #4676

Merged
merged 3 commits into from
May 10, 2022
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -13,6 +13,14 @@ env:
rust_stable: stable
rust_nightly: nightly-2022-03-21
rust_clippy: 1.52.0
# When updating this, also update:
# - README.md
# - tokio/README.md
# - CONTRIBUTING.md
hawkw marked this conversation as resolved.
Show resolved Hide resolved
# - tokio/Cargo.toml
# - tokio-util/Cargo.toml
# - tokio-test/Cargo.toml
# - tokio-stream/Cargo.toml
Comment on lines +16 to +23
Copy link
Member

Choose a reason for hiding this comment

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

There is also .clippy.toml (it is a way to tell MSRV to clippy).

msrv = "1.49"

rust_min: 1.49.0

defaults:
18 changes: 18 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -131,6 +131,24 @@ cargo check --all-features
cargo test --all-features
```

Clippy must be run using the MSRV, so Tokio can avoid having to `#[allow]` new
lints whose fixes would be incompatible with the current MSRV:
Comment on lines +134 to +135
Copy link
Member

Choose a reason for hiding this comment

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

Note that we are actually using a newer version of clippy than MSRV (it is needed for some regression tests).

rust_clippy: 1.52.0


<!--
When updating this, also update:
- .github/workflows/ci.yml
- README.md
- tokio/README.md
hawkw marked this conversation as resolved.
Show resolved Hide resolved
- tokio/Cargo.toml
- tokio-util/Cargo.toml
- tokio-test/Cargo.toml
- tokio-stream/Cargo.toml
-->

```
cargo +1.49.0 clippy --all-features
```

When building documentation normally, the markers that list the features
required for various parts of Tokio are missing. To build the documentation
correctly, use this command:
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -163,6 +163,17 @@ several other libraries, including:

## Supported Rust Versions

<!--
When updating this, also update:
- .github/workflows/ci.yml
- CONTRIBUTING.md
hawkw marked this conversation as resolved.
Show resolved Hide resolved
- tokio/README.md
hawkw marked this conversation as resolved.
Show resolved Hide resolved
- tokio/Cargo.toml
- tokio-util/Cargo.toml
- tokio-test/Cargo.toml
- tokio-stream/Cargo.toml
-->

Tokio will keep a rolling MSRV (minimum supported rust version) policy of **at
least** 6 months. When increasing the MSRV, the new Rust version must have been
released at least six months ago. The current MSRV is 1.49.0.
11 changes: 11 additions & 0 deletions tokio/README.md
Original file line number Diff line number Diff line change
@@ -163,6 +163,17 @@ several other libraries, including:

## Supported Rust Versions

<!--
When updating this, also update:
- .github/workflows/ci.yml
- CONTRIBUTING.md
hawkw marked this conversation as resolved.
Show resolved Hide resolved
- README.md
hawkw marked this conversation as resolved.
Show resolved Hide resolved
- tokio/Cargo.toml
- tokio-util/Cargo.toml
- tokio-test/Cargo.toml
- tokio-stream/Cargo.toml
-->

Tokio will keep a rolling MSRV (minimum supported rust version) policy of **at
least** 6 months. When increasing the MSRV, the new Rust version must have been
released at least six months ago. The current MSRV is 1.49.0.