#!/usr/bin/env python # coding: utf-8 # In[1]: import os import sys import getpass from BrainAnnex.modules.neo_access.neo_access import NeoAccess # In[2]: print("*** SOME DIAGNOSTIC VALUES: ***") print("\nsys.executable: ", sys.executable) print("\ncwd: ", os.getcwd()) #print("\nsys.path: ", sys.path) print("\nsys.path using separate lines: ") for p in sys.path: print(" ", p) # In[3]: print("To create a database connection, enter the host IP, but leave out the port number: (EXAMPLES: bolt://1.2.3.4 OR neo4j://localhost )\n") host = input("Enter host IP WITHOUT the port number. EXAMPLE: bolt://123.456.789.012") host += ":7687" # EXAMPLE of host value: "bolt://123.456.789.012:7687" password = getpass.getpass("Enter the database password:") print(f"\n=> Will be using: host='{host}', username='neo4j', password=**********") # In[6]: db = NeoAccess(host=host, credentials=("neo4j", password), debug=True, autoconnect=True) # In[7]: print("Version of the Neo4j driver: ", db.version()) # In[ ]: