Skip to main content

csvx: painless csv

Project description

A csv library that supports 2 and 3, does the unicode thing properly, and lets you read rows as ordered dictionaries so that the ordering stays correct by default.

Which makes things pretty easy.

Example. You’ve got a csv you want to sanitize by removing a column of passwords.

Here’s how that looks.

import csvx

with csvx.OrderedDictReader('unsanitized.csv') as csv_in:
    rows = list(csv_in)

for r in rows:
    del r['password']

with csvx.DictWriter('sanitized.csv') as csv_out:
    csv_out.write_dicts(rows)

Documentation

Full documentation is at https://csvx.readthedocs.org.

Install

Simply install with pip:

$ pip install csvx

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

csvx-0.1.1456544203.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

csvx-0.1.1456544203-py2.py3-none-any.whl (5.2 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file csvx-0.1.1456544203.tar.gz.

File metadata

File hashes

Hashes for csvx-0.1.1456544203.tar.gz
Algorithm Hash digest
SHA256 ccaef2b344689e14e7a603437dab35979187f9cfb33e137f187c7c3affac34d2
MD5 e94e9487a808b6985f87d96d3219d2f9
BLAKE2b-256 26fdc10463676f59bd2d29b695b9339a42e24dfc3303adf0c73f47b469d16828

See more details on using hashes here.

File details

Details for the file csvx-0.1.1456544203-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for csvx-0.1.1456544203-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 9b4567a382d124a7e039fb9e16861fee210ded75ec2c6f6a0672f0163a386324
MD5 c1028745f5ebb2e7c3b5655be362c8e2
BLAKE2b-256 c77206568f5434610f31ec9c9eb3d2b2b565c45eed90e0673371c5156f698d42

See more details on using hashes here.

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