Metadata-Version: 2.1
Name: gen3utils
Version: 0.5.5
Summary: Gen3 Library Template
Home-page: https://github.com/uc-cdis/gen3utils
License: Apache-2.0
Author: CTDS UChicago
Author-email: cdis@uchicago.edu
Requires-Python: >=3.6,<3.7
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Requires-Dist: cdislogging (>=1.0.0,<1.1.0)
Requires-Dist: click
Requires-Dist: dictionaryutils (>=3.0.0,<3.1.0)
Requires-Dist: gen3datamodel (>=3.0.0,<3.1.0)
Requires-Dist: gen3dictionary (>=2.0.1,<2.1.0)
Requires-Dist: gen3git (>=0.3.3,<0.4.0)
Requires-Dist: packaging (>=20.0,<20.1)
Requires-Dist: psqlgraph (>=3.0.0,<3.1.0)
Requires-Dist: pyyaml (>=5.1,<5.2)
Requires-Dist: six (>=1.12.0,<1.13.0)
Project-URL: Repository, https://github.com/uc-cdis/gen3utils
Description-Content-Type: text/markdown

# gen3utils

Utils for Gen3 commons management

## manifest.json validation

Validate one or more `manifest.json` files:
```
pip install gen3utils
gen3utils validate-manifest cdis-manifest/*/manifest.json
```

The validation settings can be updated by modifying [this file](gen3utils/manifest/validation_config.yaml).

## etlMapping.yaml validation

Validate an `etlMapping.yaml` file against the dictionary URL specified in a `manifest.json` file:
```
pip install gen3utils
gen3utils validate-etl-mapping etlMapping.yaml manifest.json
```

## Comment on a PR with any deployment changes when updating manifest services

The command requires the name of the repository, the pull request number and **a `GITHUB_TOKEN` environment variable** containing a token with read and write access to the repository. It also comments a warning if a service is pinned on a branch.
```
pip install gen3utils
gen3utils post-deployment-changes <username>/<repository> <pull request number>
```

## Running tests locally

```
poetry install -vv
poetry run pytest -vv ./tests
```

