Argo Workflows Client
Python client for Argo Workflows
Installation
pip install argo-workflows
Usage
If you're familiar with Kubernetes client, the Argo client follows the same behaviour.
from argo.workflows.client import V1alpha1Api
from argo.workflows.config import load_kube_config
load_kube_config() # loads local configuration from ~/.kube/config
And to list Workflows from a namespace (say argo):
v1alpha1 = V1alpha1Api()
wfs = v1alpha1.list_namespaced_workflows(namespace="argo")
To submit a Workflow, one would simply load it from a YAML* and submit it as such:
import requests
import yaml
namespace = "argo"
# hello-world example
resp = requests.get("https://raw.githubusercontent.com/argoproj/argo/master/examples/hello-world.yaml")
resp.raise_for_status()
manifest: dict = yaml.safe_load(resp.text)
# Submit the Workflow to the `argo` namespace
v1alpha1.create_namespaced_workflow(namespace, manifest)
* When working on a higher level of abstraction, check out the Argo Python DSL
Versioning
The client is generated from the Argo and Kubernetes OpenAPI specification.
We follow semantic versioning, the client starts at version 1.0 which matches Argo release 2.3.0 and continues onwards.
Compatibility matrix
| Argo 2.3 | Argo 2.4 | Argo 2.5 | |
|---|---|---|---|
| client-python 1.0 | ✓ | - | - |
| client-python 2.0 | + | ✓ | - |
| client-python 3.0 | + | + | ✓ |
Key:
✓Exactly the same features / API objects in both client-python and the Kubernetes version.+client-python has features or api objects that may not be present in the Kubernetes cluster, but everything they have in common will work.-The Kubernetes cluster has features the client-python library can't use (additional API objects, etc).
We try to be consistent with Argo as much as possible and hence we created special branches for user convenience --- for example argo/v2.4.0 is identical with Argo release v2.4.0.
These can be then installed directly from github:
pip install -e "git+git://github.com/CermakM/argo-client-python@argo/v2.4.0#egg=argo-workflows"
⚠️ The compatibility for such cases is not guaranteed
Code generation
If you wish to generate code yourself, you can do so by running make generate with the ARGO_VERSION environment variable being set to the you want to generate the client for.
Before
in the Makefile:
- make sure to select a compatible
KUBERNETES_BRANCHaccording to Argo's Gopkg.toml - make sure to select a compatible version of kubernetes-client
- update requirements.txt and Pipfile
For additional configuration check out the Makefile.
Metadata
Release files for argo-workflows-fvdnabee 3.6.1
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 | Actions |
|---|---|---|---|---|
| argo-workflows-fvdnabee-3.6.1.tar.gz | 223.3 kB | Without provenance | Details for argo-workflows-fvdnabee-3.6.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| argo_workflows_fvdnabee-3.6.1-py3-none-any.whl | Python 3 | none | any | Details for argo_workflows_fvdnabee-3.6.1-py3-none-any.whl |
Total release size: 604.8 kB
Release files / argo-workflows-fvdnabee-3.6.1.tar.gz
| Download URL | argo-workflows-fvdnabee-3.6.1.tar.gz |
|---|---|
| Size | 223.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
67a437d6a130f8343eb09ae0b030aad691a16f8cb8f697f2752992173ae663ff
|
|
BLAKE2b-256 checksum How to use checksums |
aace7497d190f9364cb9c578980cb93b17f04d0a42ba19c648cab758e6bbdafb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5
|
Release files / argo_workflows_fvdnabee-3.6.1-py3-none-any.whl
| Download URL | argo_workflows_fvdnabee-3.6.1-py3-none-any.whl |
|---|---|
| Size | 381.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
22deed8d3e7587033604e4f065a6729442f18d550d15761f19ac6730ab9c7cc5
|
|
BLAKE2b-256 checksum How to use checksums |
b981acee151d99f4eefec22531a4ee89a1039de3dd370c0f14aa6827e8376923
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5
|
Security for argo-workflows-fvdnabee 3.6.1
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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.