[Python-modules-team] Bug#512225: python-opengl: importing OpenGL.GLU fails
John Kozak
jk at thameslighter.net
Sun Jan 18 18:57:29 UTC 2009
Package: python-opengl
Version: 3.0.0~b6thameslighter-4
Severity: normal
Attached is console log from ipython session.
I believe this is because line 192 of baseplatform.py:
extension = original.argNames,
should actually be
extension = original.extension,
Making this change appears to fix the problem.
In [20]: from OpenGL.GLU import *
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
/home/jk/newflesh/pyggy/<ipython console> in <module>()
/usr/lib/python2.5/site-packages/OpenGL/GLU/__init__.py in <module>()
8 from OpenGL.GLU.projection import *
9 from OpenGL.GLU.tess import *
---> 10 from OpenGL.GLU.glunurbs import *
11 import ctypes
12
/usr/lib/python2.5/site-packages/OpenGL/GLU/glunurbs.py in <module>()
145
146 for (c,funcType) in GLUnurbs.CALLBACK_TYPES.items():
--> 147 cb = _callbackWithType( funcType )
148 GLUnurbs.CALLBACK_FUNCTION_REGISTRARS[ c ] = cb
149 assert funcType == GLUnurbs.CALLBACK_TYPES[c]
/usr/lib/python2.5/site-packages/OpenGL/GLU/glunurbs.py in _callbackWithType(funcType)
138 """Get gluNurbsCallback function with set last arg-type"""
139 result = platform.copyBaseFunction(
--> 140 simple.gluNurbsCallback
141 )
142 result.argtypes = [ctypes.POINTER(GLUnurbs), simple.GLenum, funcType]
/usr/lib/python2.5/site-packages/OpenGL/platform/baseplatform.py in copyBaseFunction(self, original)
190 resultType=original.restype, argTypes=original.argtypes,
191 doc = original.__doc__, argNames = original.argNames,
--> 192 extension = original.argNames,
193 )
194 def nullFunction(
/usr/lib/python2.5/site-packages/OpenGL/platform/baseplatform.py in createBaseFunction(self, functionName, dll, resultType, argTypes, doc, argNames, extension)
132 resultType=resultType, argTypes=argTypes,
133 doc = doc, argNames = argNames,
--> 134 extension = extension,
135 )
136 except AttributeError, err:
/usr/lib/python2.5/site-packages/OpenGL/platform/baseplatform.py in constructFunction(self, functionName, dll, resultType, argTypes, doc, argNames, extension)
78 raises AttributeError if can't find the procedure...
79 """
---> 80 if extension and not self.checkExtension( extension ):
81 raise AttributeError( """Extension not available""" )
82 if extension and not self.EXTENSIONS_USE_BASE_FUNCTIONS:
/usr/lib/python2.5/site-packages/OpenGL/platform/baseplatform.py in checkExtension(self, name)
156 GL_EXTENSIONS, set, context=context, weak=False
157 )
--> 158 current = set.get( name )
159 if current is None:
160 from OpenGL import extensions
TypeError: list objects are unhashable
-- System Information:
Debian Release: 5.0
APT prefers unstable
APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.26-1-openvz-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages python-opengl depends on:
ii freeglut3 2.4.0-6.1 OpenGL Utility Toolkit
ii libgl1-mesa-glx [libgl1] 7.2-1 A free implementation of the OpenG
ii libglu1-mesa [libglu1] 7.2-1 The OpenGL utility library (GLU)
ii python [python-ctypes] 2.5.2-3 An interactive high-level object-o
ii python-central 0.6.8 register and build utility for Pyt
ii python-ctypes 1.0.2-6 Python package to create and manip
ii python-pkg-resources 0.6c8-4 Package Discovery and Resource Acc
python-opengl recommends no packages.
Versions of packages python-opengl suggests:
ii libgle3 3.1.0-6 OpenGL tubing and extrusion librar
ii python-numpy 1:1.1.1-2 Numerical Python adds a fast array
ii python-tk 2.5.2-1 Tkinter - Writing Tk applications
-- debconf-show failed
More information about the Python-modules-team
mailing list