Skip to main content

Handles configuration saved as JSON files.

Project description

ConfigViper is a set of Python classes for handling configuration files saved in JSON format. For example:

from configviper import ConfigViper
conf = ConfigViper()
conf.set('a/b/c', 'd')

And the JSON file will looks like:

{
    "a": {
        "b": {
            "c": "d"
        }
    }
}

Goals

  1. Simple to define default values (avoiding “defaults” everywhere);

  2. Simple to write converters between Python and JSON types (even for complex Python types);

  3. Human editable format (JSON is readable enough);

  4. Portable configuration format (JSON is portable enough);

  5. Easy to add configuration options without destroying existing ones;

  6. Accessible anywhere in the app code (avoiding singleton’s boring discussions);

  7. Small and simple to be written by me (so anyone can use/contribute and/or point my faults).

More Documentation

For usage example and more information, please refer to the documentation available on-line.

Licensing

ConfigViper is licensed under GNU’s LGPL.

Project details


Download files

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

Source Distribution

ConfigViper-0.1.tar.gz (29.9 kB view hashes)

Uploaded Source

Built Distributions

ConfigViper-0.1.win32-py2.7.exe (208.1 kB view hashes)

Uploaded Source

ConfigViper-0.1.win32-py2.6.exe (208.1 kB view hashes)

Uploaded Source

Supported by

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