Contributing
Thank you for considering contributing to PhD Hunter! This document outlines the development workflow.
Quick Start
Fork and clone
git clone https://github.com/your-username/phd-hunter.git cd phd-hunter
Set up development environment
uv syncCreate a branch
git checkout -b feature/my-feature
Development Workflow
Write code
Follow PEP 8, use type hints.
from typing import Optional def search_professor( name: str, university: Optional[str] = None ) -> Professor: """Search for a professor by name.""" ...
Run tests
python -m pytest tests/ -v
Code formatting
uv run black . uv run ruff check .
Commit
Follow conventional commits:
feat: add arxiv batch mode fix: handle professor not found docs: update installation guide
Code Standards
Python: PEP 8, 88 character line limit
Type hints: Required for all public functions
Docstrings: Google style
Imports: stdlib -> third-party -> local
Adding Features
Add new crawler
Create
crawlers/newsource.pyInherit
BaseCrawlerImplement
fetch()methodRegister in
crawlers/__init__.pyAdd command in
main.py
Modify CLI
Add new subcommands and arguments in
main.py.
Documentation
Build documentation:
cd docs
make html
Update documentation when submitting code.
Pull Request Checklist
[ ] Code follows standards
[ ] Tests pass
[ ] Type hints are complete
[ ] Docstrings updated
[ ] Documentation updated
[ ] CHANGELOG updated
Getting Help
Email: team@phdhunter.dev
License
MIT License - see LICENSE file.