Thank you for your interest in contributing to FastHTTP! This document provides guidelines for contributing to the project.
- Python 3.10 or higher
- Git
# Clone the repository
git clone https://github.com/ndugram/fasthttp.git
cd fasthttp
# Create virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install in development mode
pip install -e ".[dev]"git checkout -b feature/your-feature-name
# or
git checkout -b fix/your-bug-fix- Write clean, readable code
- Add tests for new features
- Update documentation as needed
# Run all tests
pytest
# Run with coverage
pytest --cov=fasthttp
# Run specific test file
pytest tests/test_client.py# Format code
ruff format .
# Check for issues
ruff check .
# Type checking
mypy fasthttp/git add .
git commit -m "feat: add new feature description"git push origin feature/your-feature-nameThen create a Pull Request on GitHub.
- Follow PEP 8 guidelines
- Use type annotations
- Write descriptive docstrings
- Use meaningful variable names
Use conventional commits format:
feat:for new featuresfix:for bug fixesdocs:for documentation changesstyle:for formatting changesrefactor:for code refactoringtest:for adding testschore:for maintenance tasks
git commit -m "feat: add support for custom headers in POST requests"
git commit -m "fix: resolve timeout issue in async client"
git commit -m "docs: update quick start guide with new examples"- Write tests for all new features
- Include both positive and negative test cases
- Use descriptive test names
- Mock external dependencies
- Unit tests - Test individual functions/methods
- Integration tests - Test component interactions
- End-to-end tests - Test complete workflows
# All tests
pytest
# Specific test file
pytest tests/test_client.py
# With verbose output
pytest -v
# Skip slow tests
pytest -m "not slow"- Adding new features
- Changing existing functionality
- Fixing bugs that affect user experience
- Adding new configuration options
- README.md - Overview and basic usage
- API Reference - Detailed method documentation
- Examples - Real-world use cases
- Configuration Guide - Advanced settings
Use the bug report template and include:
- Clear description of the issue
- Steps to reproduce
- Expected vs actual behavior
- Python version and environment
- Relevant error messages
- Describe the problem you're trying to solve
- Explain how this feature would help users
- Provide examples of how it would work
- Keep PRs focused and small
- Write clear PR descriptions
- Respond to feedback promptly
- Update tests and documentation
- Be constructive and respectful
- Check code quality and tests
- Verify documentation updates
- Test locally when possible
- Version Bump - Update version in
pyproject.toml - Changelog - Update
CHANGELOG.md - Tests - Ensure all tests pass
- Documentation - Verify docs are up to date
- Release - Create GitHub release and publish to PyPI
- GitHub Issues - For bugs and feature requests
- GitHub Discussions - For questions and general discussion
- Documentation - Check existing docs first
Before submitting a PR:
- Code follows project style guidelines
- Tests added/updated for changes
- Documentation updated
- All tests pass locally
- Code is properly typed
- Commit messages are clear
- PR description explains changes
- Documentation improvements
- Bug fixes
- Test coverage improvements
- Code formatting
- New HTTP methods
- Performance optimizations
- New features
- Security enhancements
Contributors will be recognized in:
- CHANGELOG.md for significant contributions
- GitHub contributors page
- Release notes for major features
Thank you for contributing to FastHTTP! 🚀