[英]py2neo Can't run GraphServer
我在使用py2neo軟件包中的服務器時遇到問題。
這是我嘗試的方法:
from py2neo.server import GraphServer
server = GraphServer()
這導致以下異常:
FileNotFoundError: [Errno 2] No such file or directory: '.\\conf\\neo4j-server.properties'
所以我查看了安裝:
server = GraphServer("C:\Program Files (x86)\\Neo4j Community\\bin")
我得到同樣的異常:
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Program Files (x86)\\Neo4j Community\\bin\\conf\\neo4j-server.properties'
我看了一下neo4j-server.properties在哪里。 它在C:/ Users / Me / AppData / Roaming / Neo4j_Community /中,但是如果我使用它,那么它也不起作用...
py2neo版本:2.0.7。 neo4j版本2.2.1 Python 3.4 Windows 10。
我認為路徑一定有問題,但是我沒有找到任何解決方法。
我要實現的目標:我需要一個函數來關閉服務器(如果正在運行)並使用僅用於測試的數據庫啟動新進程(並在運行測試后結束服務器並重新啟動舊Graph) 。 到現在為止,我還是手動進行...
非常感謝
如文檔中服務器頁面所述,此模塊基於Linux構建,可能僅在Linux上有效。 我在Windows下不支持此功能。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.