skip to navigation
skip to content

Not Logged In

conflib 0.1.6

Manage configuration hierarchies


[![Latest Version](](
[![Coverage Status](](
[![Build Status](](
[![MIT Licensed](](

Simplifies configuration stacking. Primarily, this was written to allow stacking of default, global, and local settings for subpub. It allows for validation so that you can enforce contraints on supplied options.

## Usage

    import conflib

    Default = {'hello': 'world', 'alpha': 5}
    Global = {'wat': 'wut', 'fancy': (20, 'fish')}
    Local = {'hello': 'everybody', 'beta': 'qwerty'}

    Validator = {
        'alpha': lambda x: x < 10,
        'fancy': tuple,
        'beta': [('asdf', 'qwerty'), ('fizz','buzz')]

    my_config = conflib.Config(Default, Global, Local, validation_dict=Validator)

## Installation

    pip install conflib

## License

conflib is released under the MIT License. See the bundled LICENSE file for details.
File Type Py Version Uploaded on Size
conflib-0.1.6.tar.gz (md5) Source 2014-03-24 3KB
  • Downloads (All Versions):
  • 53 downloads in the last day
  • 305 downloads in the last week
  • 1049 downloads in the last month