[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset b97b6cc381d7 by Robert Collins in branch 'default':
Issue #13938: 2to3 converts StringTypes to a tuple. Patch from Mark Hammond.
https://hg.python.org/cpython/rev/b97b6cc381d7

--
nosy: +python-dev

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread Robert Collins

Robert Collins added the comment:

I've applied this to 3.6.

--
nosy: +rbcollins

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread R. David Murray

R. David Murray added the comment:

Looking at the audit log its not clear to me which versions Benjamin wanted 
this applied to, though it looks like 2.7 at least.

--
nosy: +r.david.murray

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset ce34c78ebf65 by Robert Collins in branch '2.7':
Issue #13938: 2to3 converts StringTypes to a tuple. Patch from Mark Hammond.
https://hg.python.org/cpython/rev/ce34c78ebf65

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread Robert Collins

Robert Collins added the comment:

So, I don't think I've ever done 2.x stuff with hg here, I'll leave this open 
till I've looked up the docs and applied it safely.


... unless you'd like to do the 2.7 application ? :)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread R. David Murray

R. David Murray added the comment:

Well, it's a patch to 2to3, which I'm assuming is sometimes (often?) run using 
2.7 to convert code to run under python3.

I personally don't use transplant in cases like this, I just apply the patch 
independently to the 2.7 branch.  That may just be because I've never used 
transplant, but we are treating the two branches as independent and I don't 
want to screw that up :)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread Robert Collins

Robert Collins added the comment:

Not clear to me either: I figured that after three years the relevance to 2.7 
was pretty low, but I can transplant it if you think thats relevant.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2015-07-22 Thread Robert Collins

Changes by Robert Collins robe...@robertcollins.net:


--
resolution:  - fixed
stage: commit review - resolved
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2014-08-22 Thread Claudiu Popa

Changes by Claudiu Popa pcmantic...@gmail.com:


--
stage:  - commit review
type:  - enhancement

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2014-07-02 Thread Mark Lawrence

Mark Lawrence added the comment:

A short patch LGTM.  Can we have a commit review please.

--
nosy: +BreamoreBoy
versions: +Python 3.4, Python 3.5 -Python 3.2, Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2012-02-15 Thread Meador Inge

Changes by Meador Inge mead...@gmail.com:


--
nosy: +meador.inge

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2012-02-06 Thread Éric Araujo

Changes by Éric Araujo mer...@netwok.org:


--
assignee:  - benjamin.peterson
nosy: +benjamin.peterson
versions: +Python 2.7 -Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13938] 2to3 fails to convert types.StringTypes appropriately

2012-02-03 Thread Mark Hammond

New submission from Mark Hammond skippy.hamm...@gmail.com:

test_types.py converts types.StringTypes to str - but types.StringTypes is 
a tuple, so expressions like type(x) in type.StringTypes fails after 
conversion with TypeError: argument of type 'type' is not iterable

Attaching a fix and test.

Note that the fixer still seems strange after this fix - types.StringType 
gets converted to bytes but types.StringTypes uses str.  This means the 
expression type.StringType in type.StringTypes evaluates to True in 2.x but 
False once converted - however, that should probably be tackled in a different 
bug - the fact the expression now causes a TypeError once converted is more 
blatantly wrong and the focus of this bug.

--
components: 2to3 (2.x to 3.x conversion tool)
files: fix_stringtypes_fixer.patch
keywords: patch
messages: 152592
nosy: mhammond
priority: normal
severity: normal
status: open
title: 2to3 fails to convert types.StringTypes appropriately
versions: Python 3.2, Python 3.3, Python 3.4
Added file: http://bugs.python.org/file24415/fix_stringtypes_fixer.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13938
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com