|
| 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. |
0 commit comments