Skip to main content

Official Python Couchbase Client

Project description


This is an experimental repository for the next generation Couchbase Python
SDK which is based on [libcouchbase][1].

The couchbase.pxd was automatically generated by a [cwrap branch that uses

NOTE: When generating the `libcouchbase.pxd` file, you _must_ add the text
`nogil` at the end of the line declaring `lcb_wait`.


Install libcouchbase.


In order to build this client, you need to have `libcouchbase` installed. Once
this is done, you can now build the extension.

python build_ext --inplace

If your libcouchbase install is in an alternate location (for example,
`/opt/local/libcouchbase'), you may add extra directives, like so:

python build_ext --inplace \
--library-dir /opt/local/libcouchbase/lib \
--include-dir /opt/local/libcouchbase/include

Or you can modify the environment `CFLAGS` and `LDFLAGS` variables.

Running sample application

To run the small sample application that inserts one million documents into
a local Couchbase at the default port 8091 and a bucket called "default",
just execute:

python examples/

Building documentaion

The documentation is using Sphinx and also needs the numpydoc Sphinx extension.
To build the documentation, go into the `docs` directory and run:

make html

The HTML output can be found in `docs/build/html/`.

Running tests

The tests need a running Couchbase instance. The values to connect to the
instance can be found in the test configuration file `tests/tests.ini`.

The test suite need several buckets which need to be created before the tests
are run. They will all have the common prefix as specified in the test
configuration file. To create them, run:

python tests/

To run the tests:


Tested platforms

So far the code has been tested on the following platforms/environments.

Linux 64-bit (with GCC):
- Python 2.7.3
- Python 3.2.3
- Python 2.6.6

Mac OS X 10.6.8
- Python 2.6.1
- Python 3.3.1

Microsoft Windows 2008 R2 (MSVC 2008/VC9)
- Python 2.7.3 (x86)
- Python 2.7.4 (x64)

If you ran it on a different platform and it worked, please let me know and
I'll add it to the list.


pylibcouchbase is licensed under the Apache License 2.0.


Project details

Release history Release notifications

Download files

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

Files for couchbase, version 0.10
Filename, size File type Python version Upload date Hashes
Filename, size couchbase-0.10.tar.gz (54.3 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

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