Skip to main content

PyCSVSchema is an implementation of CSV Schema in Python.

Project description

PyPI Page: https://pypi.python.org/pypi/pycsvschema

Github Page: https://github.com/crowdskout/PyCSVSchema

Introduction

PyCSVSchema is an implementation of CSV Schema in Python.

This project is under heavy development.

>>> from pycsvschema.checker import Validator
>>>
>>> # demo.csv:
... # id,name,value
... # 1,Ann,"5"
... # 2,Ben,"10"
... # 3,Tom,"14"
...
>>>
>>> schema = {
...     'fields': [
...         {
...             'name': 'value',
...             'type': 'number',
...             'multipleOf': 5
...         }
...     ]
... }
>>>
>>> v = Validator(filename='demo.csv', schema=schema)
>>> v.validate()

Traceback (most recent call last):
...
<ValidationError: 'Value 14.0 is not multiple of 5'; column: value; row: 3>

Installation

pip install pycsvschema

License

PyCSVSchema uses the MIT license, see LICENSE file for the details.

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

pycsvschema-0.0.6.tar.gz (8.7 kB view details)

Uploaded Source

Built Distribution

pycsvschema-0.0.6-py3-none-any.whl (13.6 kB view details)

Uploaded Python 3

File details

Details for the file pycsvschema-0.0.6.tar.gz.

File metadata

  • Download URL: pycsvschema-0.0.6.tar.gz
  • Upload date:
  • Size: 8.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.4

File hashes

Hashes for pycsvschema-0.0.6.tar.gz
Algorithm Hash digest
SHA256 aaec9dc65cb43ac3cfe8de78c95f3ac29ae4af8975571dff66c0c74cf7ec22d0
MD5 aa2a90f63b9f644f03256514fec8fcaf
BLAKE2b-256 5bf174386d0613364fd58eff8267dc1792ae6ab0bc990b62a9452f45de5252f4

See more details on using hashes here.

Provenance

File details

Details for the file pycsvschema-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: pycsvschema-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 13.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.4

File hashes

Hashes for pycsvschema-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 a8092000f8c7b086a565f76e0fbbf91d66d93576dbb539db6637801e5c16ddf2
MD5 0b7b86ffd616f157beb7fa0a98d1c3ea
BLAKE2b-256 4ffde0686cd9273c08d9df1f7cc0bd7c8bae4920521d0b0fa610528b0cd91224

See more details on using hashes here.

Provenance

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