This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Simple tool to merge JSON schemas

Project Description

Simple tool to infer and/or merge JSON schemas

Features

  • Generating schema in JSON Schema draft 4 format
  • Inferring schema from multiple samples
  • Merging schemas - nice for generating schema in Map-Reduce fashion or updating an old schema with new data

Example of using skinfer to generate a schema from a list of samples:

$ cat samples.jsonl
{"name": "Claudio", "age": 29}
{"name": "Roberto", "surname": "Gomez", "age": 72}
$ skinfer --jsonlines samples.jsonl
{
    "$schema": "http://json-schema.org/draft-04/schema",
    "required": [
        "age",
        "name"
    ],
    "type": "object",
    "properties": {
        "age": {
            "type": "number"
        },
        "surname": {
            "type": "string"
        },
        "name": {
            "type": "string"
        }
    }
}

Install with:

$ pip install skinfer

Or, if you don’t have pip, you can still install it with:

$ easy_install skinfer

History

0.2.0 (2015-08-10)

  • Renamed entry-point script schema_inferer -> skinfer
  • Added json_validator
  • Dropped Python 2.6 support
  • Added more tests

0.1.2 (2015-08-04)

  • Bugfix: removed buggy -o argument
  • Automated PyPI release via Travis

0.1.1 (2015-05-01)

  • Support more complex string-type schemas
  • Attempt to infer JSON lines format instead of just failing
  • API cleanup: no need for long imports anymore
  • Updated documentation, added docstrings
  • Fixed merging schema for arrays with tuple vs list validation
  • Fixed compatibility issues with Python 2.6
  • Improved test coverage, added end-to-end tests

0.1.0 (2015-03-03)

  • First release on PyPI.
Release History

Release History

This version
History Node

0.2.0

History Node

0.1.2

History Node

0.1.1

History Node

0.1.0

Download Files

Download Files

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

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
skinfer-0.2.0-py2.py3-none-any.whl (10.2 kB) Copy SHA256 Checksum SHA256 py2.py3 Wheel Oct 8, 2015
skinfer-0.2.0.tar.gz (22.2 kB) Copy SHA256 Checksum SHA256 Source Oct 8, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting