capless / valley

Extensible schema validations and declarative syntax helpers in Python.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

alt text

Valley

Python extensible schema validations and declarative syntax helpers.

Unittests

Installation

pip install valley

Getting Started

import valley as v


class Animal(v.Schema):
    name = v.StringProperty(required=True)
    species = v.StringProperty(required=True)
    color = v.StringProperty(required=True)
    meal_type = v.StringProperty()
    age = v.IntegerProperty(required=True)
    
frog = Animal(name='Kermit',species='frog',color='green',meal='carnivore',age=1)
frog.validate()

About

Extensible schema validations and declarative syntax helpers in Python.

License:GNU General Public License v3.0


Languages

Language:Python 82.0%Language:Jupyter Notebook 17.8%Language:Dockerfile 0.2%