Skip to main content

cwl2puml

PyPI - Version PyPI - Python Version

cwl2puml converts Common Workflow Language workflows into PlantUML diagrams.

It provides a CLI that can:

  • load a CWL workflow from a local path or URL
  • render PlantUML source files
  • optionally render PNG or SVG images through a PlantUML server

Supported Diagrams

  • activity
  • component
  • class
  • sequence
  • state

Requirements

  • Python >=3.10

Local quality checks

Install Hatch and Taskfiles and then install the Git hook:

task quality:pre-commit:install

Every commit runs Ruff (including the configured McCabe complexity limit), Ruff formatting, strict mypy checks, and the pytest suite. Run the complete hook explicitly with:

task quality:pre-commit:run

Installation

Install from the repository:

pip install .

For development:

pip install hatch

CLI Usage

Show the CLI help:

cwl2puml --help

Basic example:

cwl2puml \
  https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/cwl-workflow/pattern-1.cwl \
  --workflow-id pattern-1 \
  --output ./out

This writes one .puml file per diagram type into ./out.

Generate only selected diagrams:

cwl2puml workflow.cwl \
  --workflow-id main \
  --diagrams component \
  --diagrams sequence \
  --output ./out

Generate SVG images through a PlantUML server:

cwl2puml workflow.cwl \
  --workflow-id main \
  --diagrams component \
  --output ./out \
  --convert-image \
  --image-format svg

Use a custom PlantUML server host:

cwl2puml workflow.cwl \
  --workflow-id main \
  --output ./out \
  --convert-image \
  --puml-server uml.planttext.com

Output

For each selected diagram type, the CLI writes:

  • <diagram>.puml
  • optionally <diagram>.png or <diagram>.svg

Development

Run the test matrix:

hatch run test:test-q

Run coverage:

hatch run test:test-cov

Run formatting checks:

hatch run dev:lint

Run Ruff fixes:

hatch run dev:check

Documentation

Project documentation: https://Terradue.github.io/cwl2puml/

Contributing

Open an issue at https://github.com/Terradue/cwl2puml/issues if you find a bug or want to propose a change.

License

Apache License, Version 2.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cwl2puml-0.46.0.tar.gz (9.6 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cwl2puml-0.46.0-py3-none-any.whl (17.3 kB view details)

Uploaded Python 3

File details

Details for the file cwl2puml-0.46.0.tar.gz.

File metadata

  • Download URL: cwl2puml-0.46.0.tar.gz
  • Upload date:
  • Size: 9.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for cwl2puml-0.46.0.tar.gz
Algorithm Hash digest
SHA256 abe2c617edf8b5d425b36e8bff7d8c9eecb275ad3349cfa50983bd2d3ed0ddb8
MD5 2b0d923e04dd38c228323845a59a9d69
BLAKE2b-256 891c31845c589e4bd16b571b718091f7e05797076dfcf1724be2fc2f699749be

See more details on using hashes here.

Provenance

The following attestation bundles were made for cwl2puml-0.46.0.tar.gz:

Publisher: package.yaml on Terradue/cwl2puml

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file cwl2puml-0.46.0-py3-none-any.whl.

File metadata

  • Download URL: cwl2puml-0.46.0-py3-none-any.whl
  • Upload date:
  • Size: 17.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for cwl2puml-0.46.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ed4db2060f4a96a5bfe9bf978ce766fa62e1c296643c87d907c10b205eb1b132
MD5 5e414d0d22031228dfa653577aa6d94a
BLAKE2b-256 b9dcd928eaa7d61661c73a7a71530b01e32b907030ca7183aeb38537a18a090e

See more details on using hashes here.

Provenance

The following attestation bundles were made for cwl2puml-0.46.0-py3-none-any.whl:

Publisher: package.yaml on Terradue/cwl2puml

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.47.0

2 files

This release

0.46.0 This release

2 files

0.45.0

2 files

0.44.0

2 files

0.43.0

2 files

0.42.0

2 files

0.41.0

2 files

0.40.0

2 files

0.39.0

2 files

0.38.0

2 files

0.37.0

2 files

0.36.0

2 files

0.35.0

2 files

0.34.0

2 files

0.33.0

2 files

0.32.0

2 files

0.31.0

2 files

0.30.0

2 files

0.29.0

2 files

0.28.0

2 files

0.27.0

2 files

0.26.0

2 files

0.24.0

2 files

0.23.0

2 files

0.22.0

2 files

0.21.0

2 files

0.20.0

2 files

0.18.0

2 files

0.17.0

2 files

0.16.0

2 files

0.14.0

2 files

0.13.0

2 files

0.12.0

2 files

0.11.0

2 files

0.10.0

2 files

0.9.0

2 files

0.8.0

2 files

0.7.0

2 files

0.6.0

2 files

0.5.0

2 files

0.4.0

2 files

0.3.0

2 files

0.2.0

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page