Archive for the ‘py2neo’ Category

Py2neo 2.0

Saturday, November 15th, 2014

Py2neo 2.0 by Nigel Small.

From the webpage:

Py2neo is a client library and comprehensive toolkit for working with Neo4j from within Python applications and from the command line. The core library has no external dependencies and has been carefully designed to be easy and intuitive to use.

If you are using Neo4j or Python or both, you need to be aware of Py2Neo 2.0.

Impressive documentation!

I haven’t gone through all of it but contributed examples would be helpful.

For example:

API: Cypher

exception py2neo.cypher.ClientError(message, **kwargs)

The Client sent a bad request – changing the request might yield a successful outcome.

exception py2neo.cypher.error.request.Invalid(message, **kwargs)[source]

The client provided an invalid request.

Without an example the difference between a “bad” versus an “invalid” request isn’t clear.

Writing examples would not be a bad way to work through the Py2neo 2.0 documentation.


I first saw this in a tweet by Nigel Small.

Introducing Py2neo and Geoff

Sunday, July 8th, 2012

Introducing Py2neo and Geoff by Nigel Small. (podcast)

From the description:

Py2neo has become a popular library for Python developers to drive Neo4j’s REST API. In this presentation for the Neo4j User Group, Nigel Small describes how Py2neo evolved, provide an introduction to how it is used. Nigel also explores Geoff, a textual format for storing and transmitting graph data (with a syntax heavily influenced by Neo4j’s Cypher language) and how it powers the Neo4j REPL.

If you want to read along, slides.

I don’t know the order of Neo4j, Py2neo and Geoff in a trifecta but I do know they make a very nice triplet.

Make tonight a movie night and catch this presentation.

py2neo 1.1.0

Wednesday, March 7th, 2012

py2neo 1.1.0 – Python bindings to Neo4j by Nigel Small.

From the webpage:

The py2neo project provides bindings between Python and Neo4j via its RESTful web service interface. It attempts to be both Pythonic and consistent with the core Neo4j API and is compatible with Python 3.

Pagination with Neo4j

Thursday, September 15th, 2011

Pagination with Neo4j by Nigel Small.

I saw this on a retweet from Peter Neubauer.

Following a request on Twitter, I have spent a few hours putting together a quick article on pagination using Neo4j and more specifically the Cypher query language. Predictably, this is written from a Python standpoint and uses py2neo, but the theory should hold true for any language since all the clever bits come from Cypher.

Fundamentally, the method described here exploits the order by, skip and limit features of Cypher in order to return only a segment of the total results from the overall result set. These features are available in the latest stable version of Neo4j at the time of writing, so if you don’t have access to them already, maybe it’s time to consider an upgrade!

The longer you wait to upgrade, the more stuff you will have to learn! 😉

Please upgrade responsibly (to a stable version, but if you are brave, not!).