Skip to main content
PyPI Package latest release PyPI Package monthly downloads Supported versions Supported implementations Wheel packaging support Test line coverage Test branch coverage

options helps represent option and configuration data in a clean, high-function way. Changes can “overlay” defaults or earlier settings.

For most functions and classes, options is flexibility overkill. Not everyone wants to be a world-class gymnast, yogi, or contortionist. For most, Python’s regular function arguments, *args, **kwargs, and inheritance patterns are elegant and sufficient. options is for the top 1% that need:

  • extremely functional classes, functions, and methods,

  • with many different features and options,

  • the settings for which might be adjusted or overriden at any time,

  • yet that need “reasonable” or “intelligent” defaults, and

  • that yearn for a simple, unobtrusive API.

In those cases, Python’s built-in, inheritance-based model stops being the simple approach. Non-trivial argument-management code and complexity begins to pervade. This is where options’s layered, delegation-based approach begins to shine. Almost regardless of how varied the options it wrangles, or how much flexibility is required, code complexity remains very flat.

http://content.screencast.com/users/jonathaneunice/folders/Jing/media/02e27ff4-402d-4450-b3ee-2c7be26eb05b/00000014.png

Python has very flexible arguments for functions and methods, and good connection of values from classes to subclasses to methods. It doesn’t, however, connect those very well to configuration files, module defaults, method parameters, and other uses. options, in contrast, seamlessly connects all of these varied layers and cases.

For more backstory, see this StackOverflow.com discussion of how to combat “configuration sprawl”. options full documentation can be found at Read the Docs. For examples of options in use, see say and show.

Notes

  • Version 1.4.* is the last to support Python versions < 3.6. Time to upgrade and move to the modern age!

Metadata

Release files for options 1.4.10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for options 1.4.10
File Size Uploaded
options-1.4.10.tar.gz 200.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for options 1.4.10
File Interpreter ABI Platform
options-1.4.10-py3-none-any.whl Python 3 none any Details

Total release size: 215.9 kB

Release files / options-1.4.10.tar.gz

Download URL options-1.4.10.tar.gz
Size 200.5 kB
Tags Source
SHA-256 checksum
How to use checksums
8bfdf4f11613181880fdb8bfc7fce3717c961d495b42ab605baf1b7c94e821aa
BLAKE2b-256 checksum
How to use checksums
e22ab8f4dd8db4bfd5029564b9ba8c33dca053307a490d0f56b54c071283dc10
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.6.2 requests-toolbelt/0.9.1 tqdm/4.29.1 CPython/3.7.2

Release files / options-1.4.10-py3-none-any.whl

Download URL options-1.4.10-py3-none-any.whl
Size 15.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9625e2fdde840e45a385739fae2504f432a58002e3857fa63b1bada66c317bc6
BLAKE2b-256 checksum
How to use checksums
934b9b6336e41dc5b971aa7db120e625ca4f3c43400e3073aac67cf25f61079a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.6.2 requests-toolbelt/0.9.1 tqdm/4.29.1 CPython/3.7.2

Release history Release notifications | RSS feed

This release

1.4.10 This release

2 release files

1.4.9

2 release files

1.4.8

2 release files

1.4.7

2 release files

1.4.6

2 release files

1.4.5

2 release files

1.4.4

2 release files

1.4.3

3 release files

1.4.2

3 release files

1.4.1

3 release files

1.4.0

3 release files

1.3.2

3 release files

1.3.1

1 release file

1.3.0

3 release files

1.2.5

3 release files

1.2.2

3 release files

1.2.1

3 release files

1.2.0

2 release files

1.1.7

2 release files

1.1.6

2 release files

1.1.5

2 release files

1.1.4

2 release files

1.1.3

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.7

2 release files

1.0.6

2 release files

1.0.5

2 release files

1.0.4

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0

2 release files

0.451

2 release files

0.426

2 release files

0.420

2 release files

0.417

2 release files

0.416

2 release files

0.411

2 release files

0.402

2 release files

0.327

2 release files

0.45

2 release files

0.5

2 release 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