[Twisted-Python] python's "import" is giving me a headache.

Blake Winton bwinton at tor.dhs.org
Wed Dec 5 09:52:46 EST 2001


> >import twisted.words.service
> >from twisted import words
> >words.Service(...)
> A bit more thought - this is a bad idea.
> twisted.internet.addDelayed, but also twisted.internet.StupidProxy - 
> what's one got to do with the other? And how are they related to 
> twisted.internet.schedule? why do I have to start reading through all 
> these modules to figure out where they came from?)

What about "import twisted.words.service as WordsService"?

Then packages can name the modules whatever they want to avoid conflicts.

Later,
Blake.






More information about the Twisted-Python mailing list