Create a fork of wxee.
Download and install the package and developer dependencies from your fork.
git clone https://github.com/{username}/wxee cd wxee pip install hatch hatch run -e test pre-commit install
Create a new feature branch.
git checkout -b {feature-name}
Write features and tests and commit them (all pre-commit checks must pass). Add NumPy-style docstrings and type hints for any new functions, methods, or classes.
git add {modified file(s)} git commit -m "{commit message}"
Rebuild documentation when docstrings are added or changed.
hatch run docs:build hatch run docs:view
All new functionality should be tested. Tests that require Earth Engine to be initialized should use the @pytest.mark.ee
decorator which allows them
to be easily skipped in case of connection issues.
For example:
import pytest
@pytest.mark.ee
def test_number_is_10():
num = ee.Number(10)
assert num.getInfo() == 10
To run all tests, use hatch run test:all
. If you cannot connect to Earth Engine or would like to skip slower tests, use hatch run test:local
.