3

我一直在尝试在线学习教程,并且遵循了每一行,由于某种原因,我收到以下错误:

Traceback (most recent call last):
  File "C:/Users/User/Desktop/OpenGLContextTest.py", line 2, in <module>
    from OpenGLContext import testingcontext
  File "C:\Python27\lib\site-packages\openglcontext-2.2.0a2-py2.7.egg\OpenGLContext\testingcontext.py", line 10, in <module>
    from OpenGLContext import plugins, context, contextdefinition
  File "C:\Python27\lib\site-packages\openglcontext-2.2.0a2-py2.7.egg\OpenGLContext\context.py", line 32, in <module>
    from OpenGLContext import visitor, texturecache,plugins
  File "C:\Python27\lib\site-packages\openglcontext-2.2.0a2-py2.7.egg\OpenGLContext\visitor.py", line 3, in <module>
    from OpenGLContext.scenegraph import nodepath
  File "C:\Python27\lib\site-packages\openglcontext-2.2.0a2-py2.7.egg\OpenGLContext\scenegraph\nodepath.py", line 3, in <module>
    from vrml.vrml97 import nodepath, nodetypes
  File "C:\Python27\lib\site-packages\pyvrml97-2.3.0a2-py2.7.egg\vrml\vrml97\nodepath.py", line 4, in <module>
    from vrml import nodepath
  File "C:\Python27\lib\site-packages\pyvrml97-2.3.0a2-py2.7.egg\vrml\nodepath.py", line 3, in <module>
    from vrml import node, weaklist
  File "C:\Python27\lib\site-packages\pyvrml97-2.3.0a2-py2.7.egg\vrml\node.py", line 6, in <module>
    from vrml import field, fieldtypes, weaklist, weakkeydictfix
  File "C:\Python27\lib\site-packages\pyvrml97-2.3.0a2-py2.7.egg\vrml\field.py", line 2, in <module>
    from pydispatch import dispatcher, robustapply
ImportError: No module named pydispatch

我曾尝试在谷歌上搜索本教程可能被破坏或其他东西的可能性,但我不相信它是。我有 pydispatch 并尝试使用easy_install但没有任何更改来安装它。有人可以帮我吗?我知道代码是完全正确的,因为过了一会儿我复制并粘贴了所有内容以确保它不是我的语法。

4

3 回答 3

10

说明(显然不正确)说要安装pydispatcher. 在我安装模块之前,我遇到了同样的问题PyDispatcher。令人困惑的是,两者都存在。

于 2015-03-08T21:43:10.620 回答
4

澄清@Phil的回答。

我看见:

No module named pydispatch

所以我做了:

sudo pip install pydispatch

安装成功了,但 Scrapy 仍然没有工作,因为我们应该:

sudo pip install pydispatcher

于 2016-06-04T05:45:07.190 回答
3

您需要单独安装 PyDispatcher。请查看本教程所需的软件包以及此处的安装说明:

PyOpenGL简介

特别检查名为Package Installation的部分

于 2013-07-23T06:28:35.163 回答