Skip to main content

Basic Python utilities

Project description

Latest release: 0.3.0-dev8 (NOT YET RELEASED)

lockss-pybasic provides basic utilities for various LOCKSS projects written in Python.

Modules

lockss.pybasic.cliutil

Command line utilities based on Click Extra, Cloup and Click.

  • click_path(): a click.Path utility.

  • PositiveInt, NonNegativeInt, NegativeInt, NonPositiveInt, UInt16: click.ParamType integer types.

  • compose_decorators(): a decorator utility.

  • make_table_format_option(): a remix of click_extra.table_format_option that is not attached to the top-level command.

  • make_extra_context_settings(): a custom click_extra.ExtraContext.

lockss.pybasic.errorutil

Error and exception utilities.

  • InternalError is a no-arg subclass of RuntimeError.

lockss.pybasic.fileutil

File and path utilities.

  • file_lines returns the non-empty lines of a file stripped of comments that begin with # and run to the end of a line.

  • path takes a string or PurePath and returns a Path for which Path.expanduser() and Path.resolve() have been called.

Release Notes

See CHANGELOG.rst.

Unit Tests

Run python -m unittest discover tests at the root of the project tree (where there is a directory called tests).

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

lockss_pybasic-0.3.0.dev8.tar.gz (10.9 kB view details)

Uploaded Source

Built Distribution

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

lockss_pybasic-0.3.0.dev8-py3-none-any.whl (16.4 kB view details)

Uploaded Python 3

File details

Details for the file lockss_pybasic-0.3.0.dev8.tar.gz.

File metadata

  • Download URL: lockss_pybasic-0.3.0.dev8.tar.gz
  • Upload date:
  • Size: 10.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.14.5 Linux/7.0.11-arch1-1

File hashes

Hashes for lockss_pybasic-0.3.0.dev8.tar.gz
Algorithm Hash digest
SHA256 d8915f7c1003ca154a4aa67d86637d4e8f646747b6176d098dc1976f80c42fc0
MD5 84b4f3b5cae730eaec8cc7da3989150e
BLAKE2b-256 3922660f84570e1b0adfbb8fe6fd4941a93f2c78f38c900f05808db71c713f38

See more details on using hashes here.

File details

Details for the file lockss_pybasic-0.3.0.dev8-py3-none-any.whl.

File metadata

  • Download URL: lockss_pybasic-0.3.0.dev8-py3-none-any.whl
  • Upload date:
  • Size: 16.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.14.5 Linux/7.0.11-arch1-1

File hashes

Hashes for lockss_pybasic-0.3.0.dev8-py3-none-any.whl
Algorithm Hash digest
SHA256 86eb4bfe08e506393649034e8b24ee4914fbeb04fe7a90e0f9d7056f03dcc938
MD5 622512308a923d9736a602cf1df5523d
BLAKE2b-256 d4a5fdd38255da2d9102f03d1f34a59b413c16e3fc6cddd7f74df443290f1120

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page