Before a Pull Request: checklist for submitter
Your code is ready; you are about to push the button “Create Pull Request”! But it’s time to think a bit if your code is good enough for reviewing and doesn’t contain any silly mistakes. Here is my checklist for those who are going to create a Pull Request.
Before creating a Pull Request please check, that:
- Pull Request description contains Jira task number or Jira task url (if a Jira task exists)
- There are no debug information and
- There isn’t any commented out code
- If some code needs to be commented out, I added a
TODOmark with name, email and description why it’s commented out
- I added a new line at the end of files
- I added a Shebang if needed
- There is no dead code, present or added (no unused imports, variables, functions)
- If I did refactoring, I cleaned all the code related to my refactoring
- I created or updated
README.mdfile if needed
- No undesired files are being committed (by mistake). Ignored files are added to
- I executed a linter (
pylintfor example) against the code and fixed reported issues
- (If applicable to you) I executed
pre-commithooks against my commits and fixed reported issues
To make the process of reviewing Pull Requests more enjoyable and expected, you need a set of rules or recommendations. In this post you can find my thoughts on which rules and recommendations you can use to make the process better.
That was my quick checklist. What rules do you use? Please, share it with me!