Contributing to MagGeo
We welcome contributions to MagGeo! This document provides guidelines for contributing to the project.
Development Setup
-
Clone the repository:
git clone https://github.com/MagGeo/MagGeo-Annotation-Program.git cd MagGeo-Annotation-Program
-
Create a virtual environment:
conda env create -f environment.yml conda activate MagGeoEnv
-
Install in development mode:
pip install -e ".[dev]"
Running Tests
# Run all tests
python -m pytest tests/ -v
# Run with coverage
python -m pytest tests/ --cov=maggeo --cov-report=html
Code Style
We use Black for code formatting and flake8 for linting:
# Format code
black maggeo/ tests/
# Check linting
flake8 maggeo/ tests/
Submitting Changes
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Make your changes
- Add tests for new functionality
- Ensure all tests pass
- Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
Reporting Issues
Please use the GitHub issue tracker to report bugs or request features. Include: - Python version - Operating system - Steps to reproduce the issue - Expected behavior - Actual behavior
Documentation
Documentation improvements are always welcome! We use: - Docstrings for function documentation - README.md for general usage - Jupyter notebooks for examples
Thank you for contributing to MagGeo!