On Fri, Dec 25, 2009 at 07:49, Fabio Tranchitella <kob...@kobold.it> wrote: >> No, that's perferctly correct code and not wrong in any way. > > It is not wrong from a syntax point of view, but it is wrong because it > assumes doctest is a sub-module and not a sub-package.
I understand the difference, but the fact is that up until yesterday it *was* a submodule, and hence it was correct and valid code. There are no PEP8 rules against doing this, hence it has to be viewed as valid code. Ugly yes, but you can't say it's wrong. >> What if we hide the warning during the __init__.py import. Will it >> show up the next time, then? > > No, because modules/packages are imported only once. Right. >> Maybe we can add deprecations only for the major names in doctest.py? >> That would still raise an error everytime you use it, but only when you >> import a name, not the module. > > I thought we deprecated the whole zope.testing.doctest. Yes, we did. But now we try to get the deprecation warnings to show up in the correct place. And we could warn for the usage of some of the names, but in the message explain that doctest.py is deprecated. > Best regards, and Merry Christmas. The same! -- Lennart Regebro: Python, Zope, Plone, Grok http://regebro.wordpress.com/ +33 661 58 14 64 _______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org https://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope )