[Twisted-Python] Beginners confusion on components tutorial

Michael Lang michi+twisted at relay3.jackal-net.at
Tue Jan 4 17:04:20 EST 2005


Hi TwistedListUsers,

ive started to work with twisted, and learned from the howtos/docs on
the webpage.

I got a little bit confused on trying to understand how components work
in twisted as describe on
"http://twistedmatrix.com/documents/current/howto/components"

ive tryed the HairDryer Example and got wrong as the expected 
"AdaptToAmericanSocket" didnt work as described in the example.

as my understanding of this the example code of the HairDryer Class
is wrong, as it should call
"assert socket.voltage() == 110, 'BOOM'" 
as
"assert adapted.voltage() == 110, 'BOOM'"

which makes the example work as expected.

if im wrong please correct me and point me to my miss understanding of
the example and components.

thanks,
kind regards
Michael Lang

-- 
Michael Lang <michi+twisted at relay3.jackal-net.at>





More information about the Twisted-Python mailing list