Skip to main content
Help us improve Python packaging – donate today!

A python extension wrapper for avro-c

Project Description


A python extension wrapper for [avro-c][avro-c].

Currently only supports reading a stream of avro serialized data.
Does not support writing, nor the avro container format. For more
details on what lancaster is willing to read, see the
[lancaster spec](docs/

See also [the Avro project page][avro].


schema = '{ ... }'
with open('data.avro', 'rb') as f:
data = list(lancaster.read_stream(schema, f))

`lancaster.read_stream()` accepts a json string describing the schema,
and a stream to read from, and returns a generator which will produce
python versions of the avro data (dicts, lists, ints, strings).


A conda package is provided at [][anaconda]. This depends
on conda packages providing the C libraries required, `libsnappy`,
`jansson`, and `libavro-c`.

conda create -n lancaster -c leif python lancaster

You can also install using just pip or setuptools, assuming you have
`avro-c` and `libsnappy` installed on your system, which you can
probably get from your OS package manager. On debian and ubuntu
systems, you can install `libavro-dev` and `libsnappy-dev`.

pip install lancaster


git clone
cd lancaster
python install


Recursive structures (links) are not supported. Writing anything, and
the avro container file format, are also not supported. Happy to
accept pull requests but I don't need those features personally yet.


Copyright 2016 Two Sigma Open Source, LLC. [MIT licensed][license].


Release history Release notifications

This version
History Node


History Node


History Node


History Node


History Node


Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
lancaster-0.3.4.tar.gz (24.1 kB) Copy SHA256 hash SHA256 Source None Sep 4, 2016

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page