skip to navigation
skip to content

Not Logged In

options 1.1.7

Simple, super-flexible options. Does magic upon request.

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

For most functions and classes, options is overkill. Python’s function arguments, *args, **kwargs, and inheritance patterns are elegant and sufficient for 99.9% of all development situations. options is for the top 0.1%:

  • highly functional classes (or functions),
  • with many different features and options,
  • 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 simpler built-in, inheritance-based model adds complexity. Non-trivial options and argument-management code spreads through many individual methods. This is where options’s layered, delegation-based approach begins to shine.

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.

 
File Type Py Version Uploaded on Size
options-1.1.7.tar.gz (md5) Source 2014-12-17 205KB
options-1.1.7.zip (md5) Source 2014-12-17 219KB
  • Downloads (All Versions):
  • 111 downloads in the last day
  • 903 downloads in the last week
  • 3036 downloads in the last month