-
Notifications
You must be signed in to change notification settings - Fork 45.4k
from six.moves import xrange (en masse) #3206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
from six.moves import xrange (en masse) #3206
Conversation
Can one of the admins verify this patch? |
The xrange is imported but not used? Would this cause lint issue? |
In which file is xrange() not used? |
I was looking at the diff. They import xrange. But I don't see xrange is used in the diff. I assume they weren't used before, otherwise there would be exceptions before this change. |
Each file contains at least one call to xrange(). You can test this via:
|
Oh, I see. you changed the existing xrange to use the six xrange |
Looks good @cclauss. Thanks! |
…-xrange from six.moves import xrange (en masse)
@nealwu As requested at #3103 (comment)
For all files that use the Python 2-only builtin function xrange(), add the line from six.moves import xrange for compatibility with Python 3.