我正在尝试使用 gremlin
运行 neo4j
。我正在关注灯泡文档中的第一个示例,尝试导入 bulbs.neo4jserver
.Graph。我可以导入灯泡,它看到 gremlin,但无法使用以下命令导入图形。
>>> import bulbs
>>> bulbs.gremlin
<module 'bulbs.gremlin' from 'C:\Anaconda\lib\site-packages\bulbs\gremlin.pyc'>
>>> from bulbs.neo4jserver import Graph
Traceback (most recent call last):
File "<interactive input>", line 1, in <module>
ImportError: cannot import name Graph
我已经在 gremlin 和 rexster 上下载并运行了 maven。我在 Windows 8 中使用 Python 2.7(Anaconda 安装)工作。
您还需要了解什么?
感谢任何帮助。谢谢。
您使用的是哪个版本的 Bulbs?
$ pip freeze | grep bulbs
你应该能够做到这一点......
$ python
Python 2.7.5 (default, Feb 19 2014, 13:47:28)
Type "help", "copyright", "credits" or "license" for more information.
>>>
>>> from bulbs.neo4jserver import Graph
>>> g = Graph()
我是一名优秀的程序员,十分优秀!