Skip to content

Tools\Scripts\2to3.py broken under 3.0 rc1 Windows #48239

Closed

Description

@arnaudfaucher
BPO 3989
Nosy @loewis, @benjaminp

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2008-10-01.11:22:54.937>
created_at = <Date 2008-09-28.15:20:49.590>
labels = ['expert-2to3']
title = 'Tools\\Scripts\\2to3.py broken under 3.0 rc1 Windows'
updated_at = <Date 2008-10-01.11:22:54.935>
user = 'https://bugs.python.org/arnaudfaucher'

bugs.python.org fields:

activity = <Date 2008-10-01.11:22:54.935>
actor = 'loewis'
assignee = 'collinwinter'
closed = True
closed_date = <Date 2008-10-01.11:22:54.937>
closer = 'loewis'
components = ['2to3 (2.x to 3.x conversion tool)']
creation = <Date 2008-09-28.15:20:49.590>
creator = 'arnaud.faucher'
dependencies = []
files = []
hgrepos = []
issue_num = 3989
keywords = []
message_count = 5.0
messages = ['73974', '73975', '73977', '73980', '74124']
nosy_count = 4.0
nosy_names = ['loewis', 'collinwinter', 'benjamin.peterson', 'arnaud.faucher']
pr_nums = []
priority = 'normal'
resolution = 'fixed'
stage = None
status = 'closed'
superseder = None
type = None
url = 'https://bugs.python.org/issue3989'
versions = ['Python 3.0']

Activity

  1. arnaudfaucher commented on Sep 28, 2008

    arnaudfauchermannequin
    MannequinAuthor

    Under Windows (using the MSI), 2to3.py is outdated.

    http://svn.python.org/view/sandbox/trunk/2to3/ contains the working
    version (rev. 66173)

  2. benjaminp commented on Sep 28, 2008

    @benjaminp
    Contributor

    Could you explain what you mean be outdated please? It looks correct to
    me in the tag.
    http://svn.python.org/view/python/tags/r30rc1/Tools/scripts/2to3?rev=66500&view=markup

  3. arnaudfaucher commented on Sep 28, 2008

    arnaudfauchermannequin
    MannequinAuthor

    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) ?

  4. loewis commented on Sep 28, 2008

    loewismannequin
    Mannequin

    It was indeed the case that I had been packaging an unversioned file. I
    don't recall the details; most likely, it was a quick work-around for
    2to3 not having a .py extension, yet the MSI generator only
    incorporating .py files from Scripts.

    I'll look into it.

  5. loewis commented on Oct 1, 2008

    loewismannequin
    Mannequin

    This is now fixed in r66710 and r66711.

  6. transferred this issue fromon Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions