[Twisted-Python] with a subject this time - Woven LivePage beginners trouble

Donovan Preston dp at twistedmatrix.com
Wed Jul 16 20:46:42 MDT 2003


On Wednesday, July 16, 2003, at 5:44PM, Tim Andrews wrote:

> Hi twisted,
>
> I've just started playing with twisted and am keen to get something
> happening with  LivePage. I can serve pages quite happily from an .rpy 
> and
> have tried to follow the examples from the manual to get event 
> handlers and
> LivePage happening.  When my page is generated "MyController.handle" 
> gets
> called, but "MyController.setUp" never gets called.  If I add an 
> "__init__"
> method it gets called, but when I try to call 
> "self.view.addEventHandler" it
> complains that self.view is a NoneType.

Just move the addEventHandler into handle, that gets called after the 
view has been created and hooked up.

I'm not sure why controllers have a handle or a setUp... I really need 
to do some API pruning on Woven...

Just don't scream when I break your app and you have to rename 
something slightly! It's for the good of the community! :-)

dp





More information about the Twisted-Python mailing list