"from OpenGL.GL import *" fails because a module isn't found

Bug #587059 reported by John Otto
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
pyopengl (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: python-opengl

I am using Ubuntu Release 9.10, with version 3.0.0-0ubuntu1 of python-opengl.

I discovered the bug while trying to use Impressive version 0.10.2.

You can reproduce the bug by executing "from OpenGL.GL import *" in a python interpreter (I was using python2.6).

Specifically, this is the output when executing this command:
File "/usr/share/pyshared/OpenGL/GL/__init__.py", line 11, in <module>
    from OpenGL.GL.VERSION.GL_1_2 import *
ImportError: No module named VERSION.GL_1_2

With a little investigation, I found that there is no "__init__.py" file in the /usr/share/pyshared/OpenGL/GL/VERSION directory, meaning that the directory is not considered a package, resulting in the module not being found.

I solved the issue by creating an empty "__init__.py" file in this directory.

I checked the file list for both karmic and lucid (e.g. http://packages.ubuntu.com/karmic/all/python-opengl/filelist ) and there is no "__init__.py" file listed in this directory.

Apologies in advance if this is a duplicate report and I just wasn't looking in the right spot.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.