mailr27707 - /trunk/lib/structure/internal/molecules.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on February 20, 2015 - 16:16:
Author: bugman
Date: Fri Feb 20 16:16:02 2015
New Revision: 27707

URL: http://svn.gna.org/viewcvs/relax?rev=27707&view=rev
Log:
Python 3 fix for the new internal structural object MolContainer._sort() 
method.

The list() builtin function is required to convert the output of the range() 
function into a true
list in Python 3, so that the list.sort() method can be accessed.


Modified:
    trunk/lib/structure/internal/molecules.py

Modified: trunk/lib/structure/internal/molecules.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/lib/structure/internal/molecules.py?rev=27707&r1=27706&r2=27707&view=diff
==============================================================================
--- trunk/lib/structure/internal/molecules.py   (original)
+++ trunk/lib/structure/internal/molecules.py   Fri Feb 20 16:16:02 2015
@@ -259,7 +259,7 @@
         """Sort all structural data."""
 
         # Create an index list for sorting the structural data.
-        indices = range(len(self.atom_name))
+        indices = list(range(len(self.atom_name)))
         indices.sort(key=self._sort_key)
 
         # Sort all lists.




Related Messages


Powered by MHonArc, Updated Fri Feb 20 17:00:03 2015