Metadata-Version: 2.5
Name: p6flow
Version: 0.1.4
Summary: Parse Primavera P6 XER files into typed Snowflake-loadable Parquet.
Project-URL: Homepage, https://github.com/wllmtrng/p6flow
Project-URL: Source, https://github.com/wllmtrng/p6flow
Project-URL: Issues, https://github.com/wllmtrng/p6flow/issues
Author: Will Truong
License-Expression: LGPL-3.0-or-later
License-File: LICENSE
License-File: LICENSE-GPL
Keywords: etl,p6,parquet,primavera,project-management,scheduling,snowflake,xer
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Information Technology
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Database
Classifier: Topic :: Office/Business :: Scheduling
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: click>=8.1
Requires-Dist: duckdb>=1.0
Requires-Dist: pyarrow>=15
Provides-Extra: dev
Requires-Dist: mypy>=1.10; extra == 'dev'
Requires-Dist: pytest>=8; extra == 'dev'
Requires-Dist: ruff>=0.5; extra == 'dev'
Description-Content-Type: text/markdown

# p6flow

Parse Primavera P6 `.xer` schedule exports into typed tables. DuckDB for staging
and validation; Parquet output ready for Snowflake `COPY INTO`.

## Architecture

`%F` is ground truth. The parser reads the actual field list from each XER
block, looks up types in `src/p6flow/schema.py` (codegen'd from Oracle's
EPPM v26.4 database schema), and falls back to a heuristic + value sniffing
combo for columns the schema doesn't know about (legacy P6 columns, removed
columns, etc.). Disagreements between heuristic and sniffing fail fast.

## Install

```sh
uv sync
# or: pip install -e .[dev]
```

## Use

```sh
p6flow fixtures/sample.xer --out out/
```

Each input gets its own `out/<basename>/` containing one Parquet per table
plus `manifest.json`.

## Regenerate schema

When Oracle ships a new EPPM version:

```sh
python scripts/codegen.py --version 26.5
```
