METADATA 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158
  1. Metadata-Version: 2.1
  2. Name: neo4j
  3. Version: 5.28.1
  4. Summary: Neo4j Bolt driver for Python
  5. Author-email: "Neo4j, Inc." <drivers@neo4j.com>
  6. License: Apache License, Version 2.0
  7. Project-URL: Homepage, https://neo4j.com/
  8. Project-URL: Repository, https://github.com/neo4j/neo4j-python-driver
  9. Project-URL: Docs (Manual), https://neo4j.com/docs/python-manual/current/
  10. Project-URL: Docs (API Reference), https://neo4j.com/docs/api/python-driver/current/
  11. Project-URL: Issue Tracker, https://github.com/neo4j/neo4j-python-driver/issues
  12. Project-URL: Changelog, https://github.com/neo4j/neo4j-python-driver/wiki
  13. Project-URL: Forum, https://community.neo4j.com/c/drivers-stacks/python/
  14. Project-URL: Discord, https://discord.com/invite/neo4j
  15. Keywords: neo4j,graph,database
  16. Classifier: Development Status :: 5 - Production/Stable
  17. Classifier: Framework :: AsyncIO
  18. Classifier: Intended Audience :: Developers
  19. Classifier: License :: OSI Approved :: Apache Software License
  20. Classifier: Operating System :: OS Independent
  21. Classifier: Programming Language :: Python :: 3.7
  22. Classifier: Programming Language :: Python :: 3.8
  23. Classifier: Programming Language :: Python :: 3.9
  24. Classifier: Programming Language :: Python :: 3.10
  25. Classifier: Programming Language :: Python :: 3.11
  26. Classifier: Programming Language :: Python :: 3.12
  27. Classifier: Programming Language :: Python :: 3.13
  28. Classifier: Topic :: Database
  29. Classifier: Topic :: Software Development
  30. Classifier: Typing :: Typed
  31. Requires-Python: >=3.7
  32. License-File: LICENSE.APACHE2.txt
  33. License-File: LICENSE.PYTHON.txt
  34. License-File: LICENSE.txt
  35. License-File: NOTICE.txt
  36. Requires-Dist: pytz
  37. Provides-Extra: numpy
  38. Requires-Dist: numpy<3.0.0,>=1.7.0; extra == "numpy"
  39. Provides-Extra: pandas
  40. Requires-Dist: pandas<3.0.0,>=1.1.0; extra == "pandas"
  41. Requires-Dist: numpy<3.0.0,>=1.7.0; extra == "pandas"
  42. Provides-Extra: pyarrow
  43. Requires-Dist: pyarrow>=1.0.0; extra == "pyarrow"
  44. ****************************
  45. Neo4j Bolt Driver for Python
  46. ****************************
  47. This repository contains the official Neo4j driver for Python.
  48. Starting with 5.0, the Neo4j Drivers will be moving to a monthly release
  49. cadence. A minor version will be released on the last Friday of each month so
  50. as to maintain versioning consistency with the core product (Neo4j DBMS) which
  51. has also moved to a monthly cadence.
  52. As a policy, patch versions will not be released except on rare occasions. Bug
  53. fixes and updates will go into the latest minor version and users should
  54. upgrade to that. Driver upgrades within a major version will never contain
  55. breaking API changes.
  56. See also: https://neo4j.com/developer/kb/neo4j-supported-versions/
  57. + Python 3.13 supported (since driver version 5.26.0).
  58. + Python 3.12 supported (since driver version 5.14.0).
  59. + Python 3.11 supported (since driver version 5.3.0).
  60. + Python 3.10 supported.
  61. + Python 3.9 supported.
  62. + Python 3.8 supported.
  63. + Python 3.7 supported.
  64. Installation
  65. ============
  66. To install the latest stable version, use:
  67. .. code:: bash
  68. pip install neo4j
  69. .. TODO: 7.0 - remove this note
  70. .. note::
  71. ``neo4j-driver`` is the old name for this package. It is now deprecated and
  72. and will receive no further updates starting with 6.0.0. Make sure to
  73. install ``neo4j`` as shown above.
  74. Alternative Installation for Better Performance
  75. -----------------------------------------------
  76. You may want to have a look at the available Rust extensions for this driver
  77. for better performance. The Rust extensions are not installed by default. For
  78. more information, see `neo4j-rust-ext`_.
  79. .. _neo4j-rust-ext: https://github.com/neo4j/neo4j-python-driver-rust-ext
  80. Quick Example
  81. =============
  82. .. code-block:: python
  83. from neo4j import GraphDatabase, RoutingControl
  84. URI = "neo4j://localhost:7687"
  85. AUTH = ("neo4j", "password")
  86. def add_friend(driver, name, friend_name):
  87. driver.execute_query(
  88. "MERGE (a:Person {name: $name}) "
  89. "MERGE (friend:Person {name: $friend_name}) "
  90. "MERGE (a)-[:KNOWS]->(friend)",
  91. name=name, friend_name=friend_name, database_="neo4j",
  92. )
  93. def print_friends(driver, name):
  94. records, _, _ = driver.execute_query(
  95. "MATCH (a:Person)-[:KNOWS]->(friend) WHERE a.name = $name "
  96. "RETURN friend.name ORDER BY friend.name",
  97. name=name, database_="neo4j", routing_=RoutingControl.READ,
  98. )
  99. for record in records:
  100. print(record["friend.name"])
  101. with GraphDatabase.driver(URI, auth=AUTH) as driver:
  102. add_friend(driver, "Arthur", "Guinevere")
  103. add_friend(driver, "Arthur", "Lancelot")
  104. add_friend(driver, "Arthur", "Merlin")
  105. print_friends(driver, "Arthur")
  106. Further Information
  107. ===================
  108. * `The Neo4j Operations Manual`_ (docs on how to run a Neo4j server)
  109. * `The Neo4j Python Driver Manual`_ (good introduction to this driver)
  110. * `Python Driver API Documentation`_ (full API documentation for this driver)
  111. * `Neo4j Cypher Cheat Sheet`_ (summary of Cypher syntax - Neo4j's graph query language)
  112. * `Example Project`_ (small web application using this driver)
  113. * `GraphAcademy`_ (interactive, free online trainings for Neo4j)
  114. * `Driver Wiki`_ (includes change logs)
  115. * `Neo4j Migration Guide`_
  116. .. _`The Neo4j Operations Manual`: https://neo4j.com/docs/operations-manual/current/
  117. .. _`The Neo4j Python Driver Manual`: https://neo4j.com/docs/python-manual/current/
  118. .. _`Python Driver API Documentation`: https://neo4j.com/docs/api/python-driver/current/
  119. .. _`Neo4j Cypher Cheat Sheet`: https://neo4j.com/docs/cypher-cheat-sheet/
  120. .. _`Example Project`: https://github.com/neo4j-examples/movies-python-bolt
  121. .. _`GraphAcademy`: https://graphacademy.neo4j.com/categories/python/
  122. .. _`Driver Wiki`: https://github.com/neo4j/neo4j-python-driver/wiki
  123. .. _`Neo4j Migration Guide`: https://neo4j.com/docs/migration-guide/current/