Closed bbenne10 closed 8 years ago
This is great, thanks. I'm fine with merging everything, although a couple notes before I do:
With regard to six, I'd advocate for it. I thought about adding it in this PR, but I thought I'd start out with the smallest thing that could possibly fix the bug.
The use of list comprehensions over map calls is an improvement, imo, but I'd like to see most of them rewritten to use explicit for-loops. Particularly if they're nested._
It looks like this was written with python3 in mind, but only tested against python 2. This PR should fix the python3 implementation while not affecting the py2. The big things are the explicit calls to
list()
to exhaust themap()
iterators, a consistent usage oftext_type
versusunicode
(text_type
had existed previously, but was inconsistently utilized), and a condtional import forurlparse()
. Beyond this, there is one removal of some print statements that aren't currently reachable (these should have, imo, beenclick.echo
calls anyway) and some style fixes that are strictly opinions on m part (you're usingmap
much too heavily in this, even in places where afor-loop
is much more readable.)Feel free to merge the py3 compat fixes without merging the style fixes. I can also move those commits to another branch and open a new PR if you want to talk about them separately.