Chris, great reply.
Yes it is not easy. Especially if you wish to make use of python2 modules painless.
And I agree wholeheartedly that serious thought is needed on the 'could it work so well that it actually slow the migration of library modules?'.
This is an important debate to have. I suggest if the answer to 'can a specification be created that will significantly accelerate migration?', then it is worth the effort to deliver this.
But could it accelerate migration to python 3?
Currently, the python.org website advice on : 'Python2 or Python3 - Which version should I use?'
Lists two reasons for using python 2.
This 'shim' could eliminate that second very significant reason. Then the advice would be 'if you have a choice of version, use python 3.
And I suggest the topic of 'how do I use legacy python2 library modules?', would start by recommending if at all possible, find a python 3 replacement.
As things stand, the popularity of Python has dropped by most measures since the release of Python 3. Improve the language and lose market share? I suggest that is all about the pain of the transition.
You do not have to search hard to find comments to the effect 'nobody is using python3'. Or 'even if you use python 3, do not use the new features since you need to ensure code is compatible with both versions'.
This is worth careful thought, and again I suggest part of the answer lies in the specification. If the 'do it all' approach to a 'shim' is taken, and using python2 modules is completely painless, no one will ever bother replacing them. Make it too hard to use python2 from python3 and migration is slowed again people do not bother to port libraries because not enough users have yet migrated.
On python.org survey (2013-2014) , 60% of respondents report that dependencies are keeping them still working on python 2 and 80% are doing more code in python 2.
For most people right now... all the changes and improvements made in python 3 are simply not available and the language is frozen.
If something like this is done, without making it so painless that there is no incentive to replace or convert dependencies in a new world where the main reason for staying in python 2 has been basically eliminated, then this could be huge benefit.
Just being able to change the python.org web site to say 'use python 3 unless you have no freedom of what version runs on your environment' would be huge!