Skip to main content
Python Software Foundation 20th Year Anniversary Fundraiser  Donate today!

A config reader (yaml) that validates config files content.

Project description

https://travis-ci.org/impulsare/config.svg?branch=master https://scrutinizer-ci.com/g/impulsare/config/badges/quality-score.png?b=master

Overview

A config reader, that validates a YAML config file and add default values if required.

Extra values won’t be verified, that any component / library defines its own config parameters in a single configuration file without blocking other to do the same.

See tests/static/ for examples.

Installation / Usage

To install use pip:

$ pip install --upgrade impulsare-config

Example

from impulsare_config import Reader

# Main Config File
config_file = 'config/app.yml'
# File with validation rules based on JSON Schema
specs_file = 'config/specs.yml'
# Default values
default_file = 'config/default.yml'

config = Reader().parse(config_file, specs_file, default_file)

Development & Tests

$ pip install -r requirements.txt
$ pip install -r requirements-dev.txt
$ py.test --cov-report html --cov=impulsare_config tests/

Project details


Download files

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

Files for impulsare-config, version 1.0b5
Filename, size File type Python version Upload date Hashes
Filename, size impulsare-config-1.0b5.tar.gz (3.3 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page