Skip to content

Commit b5054e1

Browse files
docs: break up CONTRIBUTING.md into several parts (#7762)
1 parent 398eef8 commit b5054e1

File tree

8 files changed

+659
-700
lines changed

8 files changed

+659
-700
lines changed

CONTRIBUTING.md

Lines changed: 18 additions & 698 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ question. You can also ask your question on [the discussions page][discussions].
131131
you! We have a [contributing guide][guide] to help you get involved in the Tokio
132132
project.
133133

134-
[guide]: https://github.com/tokio-rs/tokio/blob/master/CONTRIBUTING.md
134+
[guide]: https://github.com/tokio-rs/tokio/blob/master/docs/contributing/README.md
135135

136136
## Related Projects
137137

docs/contributing/README.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Contributing
2+
3+
This guide will help you get started. **Do not let this guide intimidate you**.
4+
It should be considered a map to help you navigate the process.
5+
6+
## Quick start
7+
8+
If you are unsure where to begin, use the following guides:
9+
10+
- Want to report or triage a bug? Start with [Contributing in Issues](contributing-in-issues.md).
11+
- Looking for something to work on? Filter issues by [`E-help-wanted`](https://github.com/tokio-rs/tokio/labels/E-help-wanted).
12+
- Planning to submit a PR? Read [Pull Requests](pull-requests.md) for the full workflow and required checks.
13+
- Want to understand what the labels on issues mean? See [Keeping track of issues and PRs](keeping-track-of-issues-and-prs.md).
14+
- Interested in code review? See [Reviewing Pull Requests](reviewing-pull-requests.md).
15+
16+
## Table of Contents
17+
18+
- [Contributing in Issues](contributing-in-issues.md)
19+
- [Asking for General Help](contributing-in-issues.md#asking-for-general-help)
20+
- [Submitting a Bug Report](contributing-in-issues.md#submitting-a-bug-report)
21+
- [Triaging a Bug Report](contributing-in-issues.md#triaging-a-bug-report)
22+
- [Resolving a Bug Report](contributing-in-issues.md#resolving-a-bug-report)
23+
- [Pull Requests](pull-requests.md)
24+
- [Cargo Commands](pull-requests.md#cargo-commands)
25+
- [Performing spellcheck on tokio codebase](pull-requests.md#performing-spellcheck-on-tokio-codebase)
26+
- [Tests](pull-requests.md#tests)
27+
- [Integration tests](pull-requests.md#integration-tests)
28+
- [Fuzz tests](pull-requests.md#fuzz-tests)
29+
- [Documentation tests](pull-requests.md#documentation-tests)
30+
- [Benchmarks](pull-requests.md#benchmarks)
31+
- [Commits](pull-requests.md#commits)
32+
- [Commit message guidelines](pull-requests.md#commit-message-guidelines)
33+
- [Opening the Pull Request](pull-requests.md#opening-the-pull-request)
34+
- [Discuss and update](pull-requests.md#discuss-and-update)
35+
- [Commit Squashing](pull-requests.md#commit-squashing)
36+
- [Reviewing Pull Requests](reviewing-pull-requests.md)
37+
- [Review a bit at a time](reviewing-pull-requests.md#review-a-bit-at-a-time)
38+
- [Be aware of the person behind the code](reviewing-pull-requests.md#be-aware-of-the-person-behind-the-code)
39+
- [Abandoned or Stalled Pull Requests](reviewing-pull-requests.md#abandoned-or-stalled-pull-requests)
40+
- [Keeping track of issues and PRs](keeping-track-of-issues-and-prs.md)
41+
- [Area](keeping-track-of-issues-and-prs.md#area)
42+
- [Category](keeping-track-of-issues-and-prs.md#category)
43+
- [Calls for participation](keeping-track-of-issues-and-prs.md#calls-for-participation)
44+
- [Module](keeping-track-of-issues-and-prs.md#module)
45+
- [Topic](keeping-track-of-issues-and-prs.md#topic)
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
## Contributing in Issues
2+
3+
For any issue, there are fundamentally three ways an individual can contribute:
4+
5+
1. By opening the issue for discussion: For instance, if you believe that you
6+
have discovered a bug in Tokio, creating a new issue in [the tokio-rs/tokio
7+
issue tracker][issue] is the way to report it.
8+
9+
2. By helping to triage the issue: This can be done by providing
10+
supporting details (a test case that demonstrates a bug), providing
11+
suggestions on how to address the issue, or ensuring that the issue is tagged
12+
correctly.
13+
14+
3. By helping to resolve the issue: Typically this is done either in the form of
15+
demonstrating that the issue reported is not a problem after all, or more
16+
often, by opening a Pull Request that changes some bit of something in
17+
Tokio in a concrete and reviewable manner.
18+
19+
[issue]: https://github.com/tokio-rs/tokio/issues
20+
21+
**Anybody can participate in any stage of contribution**. We urge you to
22+
participate in the discussion around bugs and participate in reviewing PRs.
23+
24+
### Asking for General Help
25+
26+
If you have reviewed existing documentation and still have questions or are
27+
having problems, you can [open a discussion] asking for help.
28+
29+
In exchange for receiving help, we ask that you contribute back a documentation
30+
PR that helps others avoid the problems that you encountered.
31+
32+
[open a discussion]: https://github.com/tokio-rs/tokio/discussions/new/choose
33+
34+
### Submitting a Bug Report
35+
36+
When opening a new issue in the Tokio issue tracker, you will be presented
37+
with a basic template that should be filled in. If you believe that you have
38+
uncovered a bug, please fill out this form, following the template to the best
39+
of your ability. Do not worry if you cannot answer every detail, just fill in
40+
what you can.
41+
42+
The two most important pieces of information we need in order to properly
43+
evaluate the report is a description of the behavior you are seeing and a simple
44+
test case we can use to recreate the problem on our own. If we cannot recreate
45+
the issue, it becomes impossible for us to fix.
46+
47+
In order to rule out the possibility of bugs introduced by userland code, test
48+
cases should be limited, as much as possible, to using only Tokio APIs.
49+
50+
See [How to create a Minimal, Complete, and Verifiable example][mcve].
51+
52+
[mcve]: https://stackoverflow.com/help/mcve
53+
54+
### Triaging a Bug Report
55+
56+
Once an issue has been opened, it is not uncommon for there to be discussion
57+
around it. Some contributors may have differing opinions about the issue,
58+
including whether the behavior being seen is a bug or a feature. This discussion
59+
is part of the process and should be kept focused, helpful, and professional.
60+
61+
Short, clipped responses—that provide neither additional context nor supporting
62+
detail—are not helpful or professional. To many, such responses are simply
63+
annoying and unfriendly.
64+
65+
Contributors are encouraged to help one another make forward progress as much as
66+
possible, empowering one another to solve issues collaboratively. If you choose
67+
to comment on an issue that you feel either is not a problem that needs to be
68+
fixed, or if you encounter information in an issue that you feel is incorrect,
69+
explain why you feel that way with additional supporting context, and be willing
70+
to be convinced that you may be wrong. By doing so, we can often reach the
71+
correct outcome much faster.
72+
73+
### Resolving a Bug Report
74+
75+
In the majority of cases, issues are resolved by opening a Pull Request. The
76+
process for opening and reviewing a Pull Request is similar to that of opening
77+
and triaging issues, but carries with it a necessary review and approval
78+
workflow that ensures that the proposed changes meet the minimal quality and
79+
functional guidelines of the Tokio project.
Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
## Keeping track of issues and PRs
2+
3+
The Tokio GitHub repository has a lot of issues and PRs to keep track of. This
4+
section explains the meaning of various labels, as well as our [GitHub
5+
project][project]. The section is primarily targeted at maintainers. Most
6+
contributors aren't able to set these labels.
7+
8+
### Area
9+
10+
The area label describes the crates relevant to this issue or PR.
11+
12+
- **A-ci** This issue concerns our GitHub Actions setup.
13+
- **A-tokio** This issue concerns the main Tokio crate.
14+
- **A-readme** This issue is related to documentation such as README.md.
15+
- **A-benches** This issue concerns the benchmarks.
16+
- **A-examples** This issue concerns the examples.
17+
- **A-tokio-test** The issue concerns the `tokio-test` crate.
18+
- **A-tokio-util** This issue concerns the `tokio-util` crate.
19+
- **A-tokio-macros** This issue concerns the `tokio-macros` crate. Should only
20+
be used for the procedural macros, and not `join!` or `select!`.
21+
- **A-tokio-stream** This issue concerns the `tokio-stream` crate.
22+
23+
### Category
24+
25+
- **C-bug** This is a bug-report. Bug-fix PRs use `C-enhancement` instead.
26+
- **C-enhancement** This is a PR that adds a new features.
27+
- **C-maintenance** This is an issue or PR about stuff such as documentation,
28+
GitHub Actions or code quality.
29+
- **C-feature-request** This is a feature request. Implementations of feature
30+
requests use `C-enhancement` instead.
31+
- **C-feature-accepted** If you submit a PR for this feature request, we won't
32+
close it with the reason "we don't want this". Issues with this label should
33+
also have the `C-feature-request` label.
34+
- **C-musing** Stuff like tracking issues or roadmaps. "musings about a better
35+
world"
36+
- **C-proposal** A proposal of some kind, and a request for comments.
37+
- **C-question** A user question. Large overlap with GitHub discussions.
38+
- **C-request** A non-feature request, e.g. "please add deprecation notices to
39+
`-alpha.*` versions of crates"
40+
41+
### Calls for participation
42+
43+
- **E-help-wanted** Stuff where we want help. Often seen together with `C-bug`
44+
or `C-feature-accepted`.
45+
- **E-easy** This is easy, ranging from quick documentation fixes to stuff you
46+
can do after reading the tutorial on our website.
47+
- **E-medium** This is not `E-easy` or `E-hard`.
48+
- **E-hard** This either involves very tricky code, is something we don't know
49+
how to solve, or is challenging for some other reason.
50+
- **E-needs-mvce** This bug is missing a minimal complete and verifiable
51+
example.
52+
53+
The "E-" prefix is the same as used in the Rust compiler repository. Some
54+
issues are missing a difficulty rating, but feel free to ask on our Discord
55+
server if you want to know how challenging an issue likely is.
56+
57+
### Module
58+
59+
The module label provides a more fine grained categorization than **Area**.
60+
61+
- **M-blocking** Things relevant to `spawn_blocking`, `block_in_place`.
62+
- **M-codec** The `tokio_util::codec` module.
63+
- **M-compat** The `tokio_util::compat` module.
64+
- **M-coop** Things relevant to coop.
65+
- **M-fs** The `tokio::fs` module.
66+
- **M-io** The `tokio::io` module.
67+
- **M-macros** Issues about any kind of macro.
68+
- **M-metrics** Things relevant to `tokio::runtime::metrics`.
69+
- **M-net** The `tokio::net` module.
70+
- **M-process** The `tokio::process` module.
71+
- **M-runtime** The `tokio::runtime` module.
72+
- **M-signal** The `tokio::signal` module.
73+
- **M-sync** The `tokio::sync` module.
74+
- **M-task** The `tokio::task` module.
75+
- **M-time** The `tokio::time` module.
76+
- **M-tracing** Tracing support in Tokio.
77+
- **M-taskdump** Things relevant to taskdump.
78+
79+
### Topic
80+
81+
Some extra information.
82+
83+
- **T-docs** This is about documentation.
84+
- **T-performance** This is about performance.
85+
- **T-v0.1.x** This is about old Tokio.
86+
87+
Any label not listed here is not in active use.
88+
89+
[project]: https://github.com/orgs/tokio-rs/projects/1

0 commit comments

Comments
 (0)