Skip to main content

Contributing Guidelines

Thank you for contributing to stac-gis! To maintain code quality, security, and velocity, please follow these guidelines when submitting updates.


๐ŸŒฟ Git Flow and Pull Requestsโ€‹

  1. Fork and Branch: Create a feature branch off of main:
    git checkout -b feature/your-feature-name
  2. Commit Messages: Follow semantic commit conventions:
    • feat: add STAC catalogue parsing
    • fix: resolve JWT token expiration refresh
    • docs: update deployment guidelines
  3. Open a PR: Ensure your pull request has a clear description detailing the problem being solved and a summary of your changes.

๐ŸŽจ Code Style and Quality Standardsโ€‹

We enforce linting and formatting on both backend and frontend layers:

Backend (Python)โ€‹

We use Ruff for fast linting and formatting. Run these commands prior to committing:

# Check code style rules
ruff check .

# Fix auto-fixable lint issues
ruff check --fix .

# Format code layout
ruff format .

Frontend (TypeScript / React)โ€‹

We use ESLint and Prettier. Run these commands from the frontend workspace:

# Lint workspace apps and packages
pnpm lint

# Format codebase styles
pnpm format

๐Ÿงช Testingโ€‹

We require high test coverage on code changes. Ensure tests pass before submitting code.

Running Backend Testsโ€‹

From the backend/stacgis directory:

# Run the entire test suite
pytest

# Run tests and output an HTML coverage report
pytest --cov=app --cov-report=html

Running Frontend Testsโ€‹

From the frontend directory:

# Run tests across all workspace apps
pnpm test