MDAnalysis / mdanalysis

MDAnalysis is a Python library to analyze molecular dynamics simulations.
https://mdanalysis.org
Other
1.32k stars 652 forks source link

Apply Six fixes for Python 3 #632

Closed richardjgowers closed 8 years ago

richardjgowers commented 8 years ago

Omnibus issue for six fixes

List of issues to do:

Resources for finding fixes: http://python-future.org/compatible_idioms.html

hainm commented 8 years ago

string_types

kain88-de commented 8 years ago

You should add iteritems and co as well. Six has a wrapper function for them.

richardjgowers commented 8 years ago

Yeah, I was hoping we'd all edit the list above :P

orbeckst commented 8 years ago

Do we actually use any explicit Python 2 long anymore?

git grep '[0-9]L' | egrep '^.*\.(py|pyx|pxd):'

shows zero results. Maybe @jbarnoud or @richardjgowers can comment.

There are explicit longs in the C code but that is fine.

jbarnoud commented 8 years ago

I removed all the use of long integer I found. I do not see any remaining; except for the ones in the TRZ parser, but these are only seen by python 2.

We should be good for this issue. I close it, the remaining occurrences will most likely be fixed as we go.