Metadata-Version: 2.4
Name: roocs-woodpecker
Version: 0.7.1
Summary: Lightweight fix catalog + scaffolding for climate dataset fixes
License-Expression: Apache-2.0
Project-URL: Documentation, https://roocs.github.io/woodpecker/
Project-URL: Issues, https://github.com/roocs/woodpecker/issues
Project-URL: Repository, https://github.com/roocs/woodpecker
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: click>=8.1
Requires-Dist: lxml>=4.9
Requires-Dist: pydantic>=2.0
Requires-Dist: prov>=2.0
Requires-Dist: PyYAML>=6.0
Requires-Dist: rdflib>=7.0
Requires-Dist: xarray>=2024.1.0
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == "dev"
Requires-Dist: ruff==0.16.1; extra == "dev"
Provides-Extra: full
Requires-Dist: netCDF4>=1.6; extra == "full"
Requires-Dist: h5netcdf>=1.3; extra == "full"
Requires-Dist: scipy>=1.11; extra == "full"
Requires-Dist: zarr<3.0,>=2.13.0; extra == "full"
Requires-Dist: numcodecs>=0.12; extra == "full"
Requires-Dist: fsspec>=2024.1.0; extra == "full"
Requires-Dist: duckdb>=1.0; extra == "full"
Provides-Extra: docs
Requires-Dist: mkdocs<2; extra == "docs"
Requires-Dist: mkdocs-material>=9; extra == "docs"
Requires-Dist: mkdocs-jupyter>=0.25; extra == "docs"
Requires-Dist: jinja2>=3.1; extra == "docs"
Requires-Dist: duckdb>=1.0; extra == "docs"
Dynamic: license-file

# Woodpecker

**Small, precise fixes for climate data.**

[![CI](https://github.com/roocs/woodpecker/actions/workflows/ci.yml/badge.svg)](https://github.com/roocs/woodpecker/actions/workflows/ci.yml)
[![Docs](https://github.com/roocs/woodpecker/actions/workflows/docs.yml/badge.svg)](https://github.com/roocs/woodpecker/actions/workflows/docs.yml)
[![Online Docs](https://img.shields.io/badge/docs-online-blue)](https://roocs.github.io/woodpecker/)
[![PyPI](https://img.shields.io/pypi/v/roocs-woodpecker.svg)](https://pypi.org/project/roocs-woodpecker/)
[![License](https://img.shields.io/github/license/roocs/woodpecker)](https://github.com/roocs/woodpecker/blob/main/LICENSE)
[![Python](https://img.shields.io/badge/python-3.10%2B-blue.svg)](https://github.com/roocs/woodpecker/blob/main/pyproject.toml)

Woodpecker checks, previews, and applies known climate-data fixes through a
small Python API, CLI, and recipe system. Use it when a dataset needs a
documented repair before it enters a larger processing workflow.

```mermaid
flowchart LR
    D["Dataset"] --> C["check"]
    C --> F["findings"]
    F --> R["recipe or fix id"]
    R --> P["dry-run preview"]
    P --> A["apply"]
```

## Quick Start

Install the `roocs-woodpecker` distribution from PyPI. The Python package and
command-line program remain named `woodpecker`:

```bash
pip install roocs-woodpecker
```

For a development checkout:

```bash
conda env create -f environment.yml
conda activate woodpecker
make dev
woodpecker list-recipes
```

Run a discovered recipe:

```python
import woodpecker

recipe = woodpecker.recipe.get("cmip6.core_units")
findings = woodpecker.recipe.check(dataset, recipe)

if findings:
    woodpecker.recipe.apply(dataset, recipe, dry_run=True).preview
    woodpecker.recipe.apply(dataset, recipe, dry_run=False)
```

From the command line:

```bash
woodpecker check ./data --recipe-id cmip6.core_units
woodpecker apply ./data --recipe-id cmip6.core_units --dry-run
```

Use `woodpecker.apply(...)`, `woodpecker.recipe.apply(...)`, and
`woodpecker apply ...` for applying selected changes.

## Docs

- [Full docs](https://roocs.github.io/woodpecker/)
- [Concepts](https://roocs.github.io/woodpecker/concepts/)
- [Recipes](https://roocs.github.io/woodpecker/recipes/)
- [CLI](https://roocs.github.io/woodpecker/cli/)
- [Contributing](https://roocs.github.io/woodpecker/CONTRIBUTING_GUIDE/)

## Project Map

- `woodpecker/`: core API, CLI, recipes, fixes, stores, and results.
- `plugins/`: bundled dataset-family plugins.
- `docs/`: MkDocs pages and generated references.
- `tests/`: unit and integration tests.
- `scripts/`: docs and catalog generators.

## Development

```bash
make format
make lint
make test
make docs
```

Woodpecker is licensed under the terms in [LICENSE](LICENSE).
