[Twisted-Python] Getting deprecation warnings?

Glyph glyph at twistedmatrix.com
Wed Sep 5 13:55:29 MDT 2012


On Sep 5, 2012, at 12:11 PM, exarkun at twistedmatrix.com wrote:

> On 06:41 pm, _ at lvh.cc wrote:
>> Hey,
>> 
>> What is the appropriate way to run twistd apps in such a way that I get
>> nice and loud deprecation warnings?
> 
> 1) Have complete unit test coverage and run your tests with trial.  All 
> deprecation warnings will be written out as part of the test suite run.
> 
> 2) Run twistd with Python 2.6
> 
> 3) Run twistd with Python 2.7 and pass "-W::DeprecationWarning:"

A note for posterity - if we are ever to implement a generalized 'run an inferior twistd process', or even 'run an inferior python interpreter' mechanism, warning information like this is one of the bits of runtime state that ought to be communicated.

-glyph



More information about the Twisted-Python mailing list