Skip to main content

Convenience wrappers for the standard library csv module.

Project description


Basic context wrappers for stardard library and csv.write methods.

Writer Example


The writer returns a straight up csv.writer object:

import csvy

with csvy.writer('csvpath.csv') as csvfile:
    csvfile.writerow([1, 2, 3, 4])
Reader Example

The reader returns a proxy object that behaves a bit differently. You must call the iter method that yield an enumerator:

import csvy

with csvy.reader('csvpath.csv') as csvfile:
    for index, row in csvfile.iter():
        print(f"{index}: {row}")

If a header row is detected, the row object will be a namedtuple based on the values of the header line:


A,B,C,column D

import csvy

with csvy.reader('src.csv') as csvfile:
    for index, row in csvfile.iter():

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

csvy-0.1.5.tar.gz (3.0 kB view hashes)

Uploaded source

Built Distribution

csvy-0.1.5-py3-none-any.whl (2.6 kB view hashes)

Uploaded py3

Supported by

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