proc_pipeline_utils
Shared utility functions for Coral Atlas data pipelines
Authentication
To function properly, this code needs credentials that it can use to authenticate against the Google Earth Engine API. Credentials can be provided in one of two ways, and the code will look for them in this order:
Service Account Key. Before running this code, create an environment variable named SERVICE_ACCOUNT_KEY containing the JSON key for a Google Cloud service account with the necessary permissions to perform the actions you're trying to perform in GEE.
Personal Credentials. Before running this code, authenticate with the Google Earth Engine API using the earthengine command line tool:
$ earthengine authenticate
Remember that authentication is only required if you are planning to give coordinates through earthengine asset as input.
Development
This project uses Pipenv to manage virtual environments and dependencies. Development-time dependencies are documented in the Pipfile. Follow the Pipenv documentation to create a virtual environment and install the dependencies.
Makefile
The included Makefile prescribes actions to test, build, and publish this code to a Python Package Index (PyPI) repository as described in the following sections.
$ make [test | build | publish]
Testing
With the virtual environment active and the dependencies installed, use pytest to run the test suite.
To run the unit tests, run:
$ pipenv run pytest
Building
This project uses the setuptools Python package for packaging as described here.
When building via the make build command, you may optionally append to the package name using the prerelease argument. For example, if the current version of pipelines_utils specified in the setup.py module is 1.0.1, then
$ make build prerelease=rc1
will produce a package named pipelines_utils-1.0.1rc1. The default is a beta prerelease name incremented by each git commit (eg/ 1.0.1b7 for the seventh commit on this branch). Specify a final release with
$ make build prerelease=""
Note that prerelease names must comply with PEP 440.
Publishing
This project uses the twine Python package for distribution as described here.
When publishing via the make publish command, the default PyPI repository is testpypi. To publish to pypi.org, specify that repository:
$ make publish pypi_repository=pypi
The credentials necessary to publish to the target PyPI repository can be provided in one of two ways.
- As these environment variables:
| Env Var | Notes |
|---|---|
PYPI_REPOSITORY_USERNAME |
PyPI account username. If authenticating using a token, use the literal string __token__. |
PYPI_REPOSITORY_PASSWORD |
PyPI account password. If authenticating using a token, use the token contents. |
- At the
make publishcommand:
$ make publish pypi_repository=pypi pypi_repository_username="foo" pypi_repository_password="bar"
Metadata
Release files for pipeline-utils 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| pipeline_utils-0.0.2.tar.gz | 4.2 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pipeline_utils-0.0.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.9 kB
Release files / pipeline_utils-0.0.2.tar.gz
| Download URL | pipeline_utils-0.0.2.tar.gz |
|---|---|
| Size | 4.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
29c6bf6a69b504fef5e1673092d17cf1399308282f89e4097503687040431f07
|
|
BLAKE2b-256 checksum How to use checksums |
65ed66a6e32e185edc477f2c1be759e283e538936af7d1b7d487ee5b3a31f4c0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.6.1 requests/2.25.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.53.0 CPython/3.6.12
|
Release files / pipeline_utils-0.0.2-py3-none-any.whl
| Download URL | pipeline_utils-0.0.2-py3-none-any.whl |
|---|---|
| Size | 8.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ef3466f2ef6d354ba1dfda3c3f93323a82d9d54f7e82e8d6287ae1f57de36d45
|
|
BLAKE2b-256 checksum How to use checksums |
640bc8cb35281e1d7d0b27e091c54580b7e59464827a194ec33ee3a0a5078c00
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.6.1 requests/2.25.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.53.0 CPython/3.6.12
|
Security for pipeline-utils 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.