Skip to main content

Pull Requests

Overview​

Guidelines for creating and reviewing pull requests.

Creating a Pull Request​

Before You Start​

  1. Check if issue exists for your change
  2. Discuss large changes first
  3. Fork and clone the repository
  4. Create a feature branch

PR Template​

## Description
Brief description of changes

## Type of Change
- [ ] Bug fix
- [ ] New feature
- [ ] Breaking change
- [ ] Documentation update

## Testing
How were these changes tested?

## Screenshots
If applicable

## Related Issues
Closes #123

Commit Messages​

Use conventional commits format:

feat: add new feature
fix: resolve bug
docs: update documentation
test: add tests
refactor: improve code structure
style: formatting changes
chore: maintenance tasks

PR Best Practices​

Keep PRs Small​

  • Focus on single feature/bug
  • Break large changes into smaller PRs
  • Easier to review and merge

Write Clear Description​

  • Explain what and why
  • Include testing instructions
  • Link related issues

Add Tests​

  • Unit tests for new features
  • Update existing tests if needed
  • Ensure all tests pass

Update Documentation​

  • Update relevant docs
  • Add inline code comments
  • Update README if needed

Review Process​

Self-Review​

  1. Review your own changes first
  2. Check for debugging code
  3. Verify tests pass
  4. Run linting tools

Reviewer Checklist​

  • Code follows standards
  • Tests are adequate
  • Documentation updated
  • No security issues
  • Performance acceptable

Addressing Feedback​

  • Respond to all comments
  • Make requested changes
  • Push updates to same branch
  • Request re-review when ready

Merging​

Merge Requirements​

  • All checks must pass
  • At least one approval
  • No merge conflicts
  • Up to date with main branch

Merge Strategy​

  • Squash and merge for features
  • Rebase and merge for bug fixes
  • Merge commit for releases

After Merge​

  • Delete feature branch
  • Close related issues
  • Monitor for issues
  • Update project board

Common Issues​

Merge Conflicts​

git fetch upstream
git rebase upstream/main
# Resolve conflicts
git push --force-with-lease

Failed Checks​

  • Review error messages
  • Fix issues locally
  • Push corrections

Questions?​

Ask in PR comments or discussions.