1
votes

Earlier my code was working fine, suddenly while running my Python script:

**from neo4jrestclient.client import GraphDatabase
from bottle import route, run,template,post,request,redirect
gdb = GraphDatabase("http://localhost:7474/db/data/")*
@route('/home')
def open_home():
    username=""
    parties=[]
    return template('home',dict(username=username,parties=parties))

This error shows up:

Traceback (most recent call last): > File "bottle3.py", line 4, in > gdb = > GraphDatabase("localhost:7474/db/data/") File > "/usr/local/lib/python2.7/dist-packages/neo4jrestclient/client.py", > > line 78, in init > raise NotFoundError(response.status_code, "Unable get root") neo4jrestclient.exceptions.NotFoundError: Code > [411]: Length Required. > Client must specify Content-Length.. Unable > get root

1
i believe you are running the script by another user than before - ulkas
Which versions of neo4jrestclient and Neo4j are you running? - Javier de la Rosa
version 2.1.3 for linux - smartsn123

1 Answers

3
votes

Have you removed all nodes in the database?

Have you upgraded to Neo4j >=2.0? With the release of 2.0.0 RC1 the database no longer contains a default node 0 (reference node), previously known as root.

I can recommend neo4jdb-python for an up to date python driver.