nicolewhite / neo4j-flask

Flaskr Extended with Neo4j and Py2neo.
http://nicolewhite.github.io/neo4j-flask/
312 stars 114 forks source link

Building a Python Web Application Using Flask and Neo4j #21

Open B3DS-D01 opened 6 years ago

B3DS-D01 commented 6 years ago

File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\database__init.py", line 318, in new inst = cls.instances[key] KeyError: (<class 'py2neo.database.Graph'>, <ServerAddress settings={'host': 'localhost', 'http_port': 7474}>, 'data') During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\packages\httpstream\http.py", line 322, in submit response = send() File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\packages\httpstream\http.py", line 317, in send http.request(xstr(method), xstr(uri.absolute_path_reference), body, headers) File "C:\Users\abc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1239, in request self._send_request(method, url, body, headers, encode_chunked) File "C:\Users\abc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1285, in _send_request self.endheaders(body, encode_chunked=encode_chunked) File "C:\Users\abc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1234, in endheaders self._send_output(message_body, encode_chunked=encode_chunked) File "C:\Users\abc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1026, in _send_output self.send(msg) File "C:\Users\abc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 964, in send self.connect() File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\packages\httpstream\http.py", line 80, in connect self.source_address) File "C:\Users\abc\AppData\Local\Programs\Python\Python36-32\lib\socket.py", line 724, in create_connection raise err File "C:\Users\abc\AppData\Local\Programs\Python\Python36-32\lib\socket.py", line 713, in create_connection sock.connect(sa) ConnectionRefusedError: [WinError 10061] No connection could be made because the target machine actively refused it During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Program Files\JetBrains\PyCharm 2018.1.2\helpers\pydev\pydevd.py", line 1664, in main() File "C:\Program Files\JetBrains\PyCharm 2018.1.2\helpers\pydev\pydevd.py", line 1658, in main globals = debugger.run(setup['file'], None, None, is_module) File "C:\Program Files\JetBrains\PyCharm 2018.1.2\helpers\pydev\pydevd.py", line 1068, in run pydev_imports.execfile(file, globals, locals) # execute the script File "C:\Program Files\JetBrains\PyCharm 2018.1.2\helpers\pydev_pydev_imps_pydev_execfile.py", line 18, in execfile exec(compile(contents+"\n", file, 'exec'), glob, loc) File "C:/Users/abc/PycharmProjects/FlaskWithNeo4j/run.py", line 1, in from blog import app File "C:\Users\abc\PycharmProjects\FlaskWithNeo4j\blog__init.py", line 1, in from .views import app File "C:\Users\abc\PycharmProjects\FlaskWithNeo4j\blog\views.py", line 1, in from .models import User, get_todays_recent_posts File "C:\Users\abc\PycharmProjects\FlaskWithNeo4j\blog\models.py", line 11, in graph = Graph(url + '/db/data/') File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\database__init.py", line 327, in new use_bolt = version_tuple(inst.remote__.get().content["neo4j_version"]) >= (3,) File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\database\http.py", line 154, in get response = self.base.get(headers=headers, redirect_limit=redirect_limit, kwargs) File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\packages\httpstream\http.py", line 966, in get return self.__get_or_head("GET", if_modified_since, headers, redirect_limit, kwargs) File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\packages\httpstream\http.py", line 943, in __get_or_head return rq.submit(redirect_limit=redirect_limit, **kwargs) File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\packages\httpstream\http.py", line 433, in submit http, rs = submit(self.method, uri, self.body, self.headers) File "C:\Users\abc\venv\untitled2\lib\site-packages\py2neo\packages\httpstream\http.py", line 362, in submit raise SocketError(code, description, host_port=uri.host_port) py2neo.packages.httpstream.http.SocketError: Unknown error

jankubierecki commented 6 years ago

Make sure you've installed neo4j globally first and have it running.