简体   繁体   English

从py2neo启动并连接到neo4j时出错

[英]error in starting and connecting to neo4j from py2neo

I am trying to connect to neo4j from py2neo: 我正在尝试从py2neo连接到neo4j:

    from py2neo.server import GraphServer
    server=GraphServer()
    server.start()

At this stage when I check the logs I see that the server is up and running: 在此阶段,当我检查日志时,我看到服务器已启动并正在运行:

    2016-06-10 09:41:09.928-0600 INFO  Initiating metrics..
    2016-06-10 09:42:01.288-0600 INFO  Successfully started database
    2016-06-10 09:42:01.305-0600 INFO  Starting HTTP on port 7474 (40 threads available)
   2016-06-10 09:42:01.428-0600 INFO  Mounted REST API at: /db/manage
   2016-06-10 09:42:01.472-0600 INFO  Mounting static content at /webadmin
   2016-06-10 09:42:01.509-0600 INFO  Mounting static content at /browser
  2016-06-10 09:42:03.085-0600 INFO  Remote interface ready and available at http://0.0.0.0:7474/

But in ipython I get the below error: 但是在ipython中,出现以下错误:

       TypeError                                 Traceback (most recent call  last)
<ipython-input-46-5e4be8f41f99> in <module>()
 ----> 1 server.start()

  /usr/local/lib/python2.7/dist-packages/py2neo/server.pyc in start(self)
190             uri = None
191             kwargs = {}
--> 192             for line in out.decode("utf-8").splitlines(keepends=False):
193                 if line.startswith("Using additional JVM arguments:"):
194                     kwargs["jvm_arguments"] = shlex.split(line[32:])

 TypeError: splitlines() takes no keyword arguments

If any more info is needed please feel free to ask for it. 如果需要更多信息,请随时提出要求。

Which versions of Python, Neo4j and py2neo are you using? 您正在使用哪个版本的Python,Neo4j和py2neo? Are they listed as supported versions on py2neo.org? 它们是否在py2neo.org上列为受支持的版本?

作为一项变通办法,我一直在使用./bin/neo4j start从linux本身启动Neo4j,即使我从linux注销,它仍然保持启动状态。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM