[issue3989] Tools\Scripts\2to3.py broken under 3.0 rc1 Windows

arnaud.faucher report at bugs.python.org
Sun Sep 28 19:03:20 CEST 2008


arnaud.faucher <arnaud.faucher at gmail.com> added the comment:

On a fresh win32 installation (using the 3.0rc1 MSI), the C:\Python30
\Tools\Scripts\2to3.py file contents is as follows:

------------------------------------------
#!/usr/bin/env python
from lib2to3 import refactor
import sys

sys.exit(refactor.main())
------------------------------------------

This version throws an error as follows:

------------------------------------------
C:\Python30\Tools\Scripts>C:\Python30\python.exe 2to3.py
Traceback (most recent call last):
  File "2to3.py", line 5, in <module>
    sys.exit(refactor.main())
AttributeError: 'module' object has no attribute 'main'
------------------------------------------


It seems that the '.py' extendion of the 2to3 script was removed some 
time ago.

Perhaps the MSI build process uses an old version of '2to3.py' and not 
the newer version of '2to3' (without the '.py' extension) ?

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue3989>
_______________________________________


More information about the Python-bugs-list mailing list