wxPython and Twisted.

"H�kan Johansson" <hackett@bredband.tiscali.se> wrote in message
news:oprv1r9pk44gw6by@mail.bredband.tiscali.se...

Hello all!
I am trying to get Twisted to work with wxPython but ran in to some
problems.
I searched the wxPython lists and saw a discussion on this matter, but it
seems alot has happend since then.
Twisted is now suppose to have builtin support for wxPython using something
like this:

from wxPython.wx import *
from twisted.internet import wxsupport, reactor

myWxAppInstance = MyWxApp(0)
wxsupport.install(myWxAppInstance)
reactor.run()

There is also a demo in /doc/examples called wxDemo.py.
This should work I think (since I didn't write it myself!) but it doesn't.
Execution halts with this error:

signal.signal(signal.SIGINT, self.sigInt)
SystemError: error return without exception set

I have searched all over for a solution and tried at least three diffrent
solutions but nothing
seems to work.
Has anyone got any experience with this? Im using wxPython 2.4.1.2, Python
2.3 and Twisted 1.07 under
Windows XP proffesional.

The following might not directly address your specific question but it is
essential reading if you try to mix twisted with wxPython apparently:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/181780

···

--
Mike

I have tried this code snippet before and it produces the exact same error message.
If anyone has gotten wxPython to work together with Twisted im interested in what version
of Python, Twisted and wxPython they are using. It has worked in older versions it seems
since there are some example code on the net.

···

On Thu, 25 Sep 2003 23:06:48 +1000, Mike Thompson <mike.thompson@day8.com.au> wrote:

"HÃ¥kan Johansson" <hackett@bredband.tiscali.se> wrote in message
news:oprv1r9pk44gw6by@mail.bredband.tiscali.se...

Hello all!
I am trying to get Twisted to work with wxPython but ran in to some
problems.
I searched the wxPython lists and saw a discussion on this matter, but it
seems alot has happend since then.
Twisted is now suppose to have builtin support for wxPython using something
like this:

from wxPython.wx import *
from twisted.internet import wxsupport, reactor

myWxAppInstance = MyWxApp(0)
wxsupport.install(myWxAppInstance)
reactor.run()

There is also a demo in /doc/examples called wxDemo.py.
This should work I think (since I didn't write it myself!) but it doesn't.
Execution halts with this error:

signal.signal(signal.SIGINT, self.sigInt)
SystemError: error return without exception set

I have searched all over for a solution and tried at least three diffrent
solutions but nothing
seems to work.
Has anyone got any experience with this? Im using wxPython 2.4.1.2, Python
2.3 and Twisted 1.07 under
Windows XP proffesional.

The following might not directly address your specific question but it is
essential reading if you try to mix twisted with wxPython apparently:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/181780

--
Mike

Replace the line

reactor.startRunning()

by

reactor.startRunning(installSignalHandlers=0)

UC

···

On Thursday 25 September 2003 07:12 am, Håkan Johansson wrote:

On Thu, 25 Sep 2003 23:06:48 +1000, Mike Thompson > > <mike.thompson@day8.com.au> wrote:
> "Håkan Johansson" <hackett@bredband.tiscali.se> wrote in message
> news:oprv1r9pk44gw6by@mail.bredband.tiscali.se...
>
>> Hello all!
>> I am trying to get Twisted to work with wxPython but ran in to some
>> problems.
>> I searched the wxPython lists and saw a discussion on this matter, but
>> it
>> seems alot has happend since then.
>> Twisted is now suppose to have builtin support for wxPython using
>> something
>> like this:
>>
>> from wxPython.wx import *
>> from twisted.internet import wxsupport, reactor
>>
>> myWxAppInstance = MyWxApp(0)
>> wxsupport.install(myWxAppInstance)
>> reactor.run()
>>
>> There is also a demo in /doc/examples called wxDemo.py.
>> This should work I think (since I didn't write it myself!) but it
>> doesn't.
>> Execution halts with this error:
>>
>> signal.signal(signal.SIGINT, self.sigInt)
>> SystemError: error return without exception set
>>
>> I have searched all over for a solution and tried at least three
>> diffrent
>> solutions but nothing
>> seems to work.
>> Has anyone got any experience with this? Im using wxPython 2.4.1.2,
>> Python
>> 2.3 and Twisted 1.07 under
>> Windows XP proffesional.
>
> The following might not directly address your specific question but it is
> essential reading if you try to mix twisted with wxPython apparently:
> http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/181780
>
> --
> Mike

I have tried this code snippet before and it produces the exact same error
message.
If anyone has gotten wxPython to work together with Twisted im interested
in what version
of Python, Twisted and wxPython they are using. It has worked in older
versions it seems
since there are some example code on the net.

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwindows.org
For additional commands, e-mail: wxPython-users-help@lists.wxwindows.org

--
Open Source Solutions 4U, LLC 2570 Fleetwood Drive
Phone: +1 650 872 2425 San Bruno, CA 94066
Cell: +1 650 302 2405 United States
Fax: +1 650 872 2417

Uwe C. Schroeder wrote:

Replace the line

reactor.startRunning()

by

reactor.startRunning(installSignalHandlers=0)

There are some fixes coming in 2.4.2.x that should make this unnecessary.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Looking forward to see them :slight_smile:

  UC

···

On Monday 29 September 2003 03:06 pm, Robin Dunn wrote:

Uwe C. Schroeder wrote:
> Replace the line
>
> reactor.startRunning()
>
> by
>
> reactor.startRunning(installSignalHandlers=0)

There are some fixes coming in 2.4.2.x that should make this unnecessary.

--
Open Source Solutions 4U, LLC 2570 Fleetwood Drive
Phone: +1 650 872 2425 San Bruno, CA 94066
Cell: +1 650 302 2405 United States
Fax: +1 650 872 2417