Skip to main content

TSArP - Type-Safe Argument Parser

Copyright 2026 Ian Pilcher <arequipeno@gmail.com>

Overview

TSArP (pronounced like "zarp") is a wrapper around Python's argparse module that supports static type-safety.

Limitations

TSArP is very much alpha software.

  • It currently supports only a fraction of the full functionality of argparse.

  • Python 3.14 or later is required.

  • Inheritance of schema attributes (types, groups, arguments, etc.) is not possible.

  • The API is very much in flux.

  • Lots of edge cases remain to be worked out.

Despite this, it is still useful.

Use

The basic usage pattern is:

  1. Create any custom types (instances of tsarp.Type).

  2. Create a schema (a subclass of tsarp.Schema) for any subcommands and the top-level command-line interface.

  3. Call tsarp.parse(), passing the top-level schema class as the first argument.

  4. tsarp.parse() returns an instance of the top-level schema class (containing instances of any subcommand schemas that were invoked).

See also

Download files

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

Source Distribution

tsarp-0.0.1.tar.gz (37.0 kB view details)

Uploaded Source

Built Distribution

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

tsarp-0.0.1-py3-none-any.whl (18.2 kB view details)

Uploaded Python 3

File details

Details for the file tsarp-0.0.1.tar.gz.

File metadata

  • Download URL: tsarp-0.0.1.tar.gz
  • Upload date:
  • Size: 37.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for tsarp-0.0.1.tar.gz
Algorithm Hash digest
SHA256 bbfd9cdff4b938940baf54e6208b9a006721201187b0176257ef7e1671c04305
MD5 cea1e9af5b2347c02ea6d280ae28fdf4
BLAKE2b-256 fc0b35f815ff1391c01b9f9638296802b03c1c0fd161b26336a38589ca0979f5

See more details on using hashes here.

Provenance

The following attestation bundles were made for tsarp-0.0.1.tar.gz:

Publisher: python-publish.yml on ipilcher/tsarp

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

File details

Details for the file tsarp-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: tsarp-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 18.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for tsarp-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a5ba374cc934693f34448c9c5bc849393ab1edfea78cab5c36b4cff4370ea154
MD5 3ed22f4705b30fe00b2288e8d5377348
BLAKE2b-256 6889de1736cf7ac139ac894aaba049c2cdb976d329aa8f4ae257b20edd617604

See more details on using hashes here.

Provenance

The following attestation bundles were made for tsarp-0.0.1-py3-none-any.whl:

Publisher: python-publish.yml on ipilcher/tsarp

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.0.2

2 files

This release

0.0.1 This release

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