Skip to content

UnboundLocalError: local variable 'handshake' referenced before assignment #1143

@pwrstar

Description

@pwrstar

Neo4j Version: 5.28.0
Operating System: Amazon Linux
Installation Method: Pip
API: Python

Steps to reproduce

  1. pip install graphdatascience==1.12, which will install "neo4j==5.28.0" as the req indicate Requires-Dist: neo4j<6.0,>=4.4.12. try to connect to neo4j using the GraphDataScience
  2. from graphdatascience import GraphDataScience
  3. connect to Neo4j using: gds = GraphDataScience(bolt_url, auth=(neo4j_user, neo4j_password), aura_ds=False)

Expected behavior

  • The authentication should work and create gds instance.

Actual behavior

  • It throws error graphdatascience.error.unable_to_connect.UnableToConnectError: local variable 'handshake' referenced before assignment

neo4j-5.27 works

  • Now, pip install neo4j=5.27 and then repeat the steps again, the connection works with no issues.

Issue:

The handshake variable seems be introduced in neo4j=5.28 , which is breaking the flow.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions