On Mon, May 19, 2008 at 2:23 PM, Alexandre Vassalotti
On Mon, May 19, 2008 at 3:21 PM, Brett Cannon
wrote: Apparently pickle doesn't like the way renames have been handled in 2.6 and people don't want to mess with pickle, so that means the renames need to change.
So, here is my idea (only need to care about modules that have stuff to pickle, e.g., don't need to change test.support):
* Rename lib-old to lib-new
* Change the names in lib-new to the new names.
* Change the names in the stdlib to the old names.
* Move the Py3K warnings out of the stubs in lib-new and put them in the modules directly stored in the stdlib.
* Change the imports in the stubs in lib-new to import the old name and suppress the Py3K warning (probably use test.support.catch_warning() with a *very* specific ignore filter).
I think that gets __module__ set to the old module name even when code is imported with the new name. It should also allow the Py3K warnings to stick around without causing issues when importing from the new name or suppressing other Py3K warnings. What do people think?
Sound fine to me. Although this is going to be mess, it seems to be our only reasonable choice.
Yes, it will be a pain. I have not exactly been in high spirits since this came up. But we can move each module on its own so at least it does not need to be done en-masse. -Brett