Wx broken?

T

tmallen

I've tried a few of the examples from http://wiki.wxpython.org/Getting Started
, but after "Hello World" (window) nothing works. I get the following
error message with the other examples:

Traceback (most recent call last):
File "C:/Documents and Settings/MyUserName/Desktop/WxExample.py",
line 1, in <module>
import wx
File "C:\Python25\lib\site-packages\wx-2.8-msw-unicode\wx
\__init__.py", line 45, in <module>
from wx._core import *
File "C:\Python25\lib\site-packages\wx-2.8-msw-unicode\wx\_core.py",
line 6, in <module>
new_instancemethod = new.instancemethod
AttributeError: 'module' object has no attribute 'instancemethod'

Here's a snippet that generates this error:
http://pastebin.com/m2b4f4f9c

For those familiar with wx here, is this a bug in the library, or
should I be providing "instancemethod" at some point? Seeing that it's
an unhandled exception, I do expect the former.

Thanks,
Thomas
 
T

tmallen

I've tried a few of the examples fromhttp://wiki.wxpython.org/Getting%20Started
, but after "Hello World" (window) nothing works. I get the following
error message with the other examples:

Traceback (most recent call last):
  File "C:/Documents and Settings/MyUserName/Desktop/WxExample.py",
line 1, in <module>
    import wx
  File "C:\Python25\lib\site-packages\wx-2.8-msw-unicode\wx
\__init__.py", line 45, in <module>
    from wx._core import *
  File "C:\Python25\lib\site-packages\wx-2.8-msw-unicode\wx\_core.py",
line 6, in <module>
    new_instancemethod = new.instancemethod
AttributeError: 'module' object has no attribute 'instancemethod'

Here's a snippet that generates this error:http://pastebin.com/m2b4f4f9c

For those familiar with wx here, is this a bug in the library, or
should I be providing "instancemethod" at some point? Seeing that it's
an unhandled exception, I do expect the former.

Thanks,
Thomas

Looking a little closer, this is what's causing the bug:

Wx: _core.py, lines 1-6:

# This file was created automatically by SWIG 1.3.29.
# Don't modify this file, modify the SWIG interface instead.

import _core_
import new
new_instancemethod = new.instancemethod

On this Win32 box, the "new" module doesn't have the "instancemethod"
attribute. What is new.instancemethod used for? "new_instancemethod,"
which should be assigned to the attr, does not show up again in this
particular source file.

Thanks,
Thomas
 
T

tmallen

I'm guessing you either have a python file called 'new.py' in your
working directory, or you have one in your pythonpath.

--Mark

That's correct. Thanks!

Thomas
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,767
Messages
2,569,570
Members
45,045
Latest member
DRCM

Latest Threads

Top