[NumPy-Tickets] [NumPy] #1616: numpy.loadtxt uses both file-like and iterator interfaces instead of just one

NumPy Trac numpy-tickets@scipy....
Sat Mar 26 11:57:08 CDT 2011


#1616: numpy.loadtxt uses both file-like and iterator interfaces instead of just
one
-------------------------+--------------------------------------------------
 Reporter:  zachrahan    |       Owner:  somebody
     Type:  enhancement  |      Status:  new     
 Priority:  normal       |   Milestone:  1.5.1   
Component:  Other        |     Version:  devel   
 Keywords:               |  
-------------------------+--------------------------------------------------

Comment(by derek):

 Replying to [ticket:1616 zachrahan]:
 Seems reasonable; note interferences with #1752 though. I've run the
 'full' test suite from 1.6.0beta1 with this patch in Python2.6.6 and
 Python3.2.

 >          for i in xrange(skiprows):
 > -            fh.readline()
 > +            try:
 > +                fh.next()

 For Python3 compatibility this should be changed to next(fh) since it has
 only BytesIO.__next__()
 Otherwise all tests pass.

-- 
Ticket URL: <http://projects.scipy.org/numpy/ticket/1616#comment:1>
NumPy <http://projects.scipy.org/numpy>
My example project


More information about the NumPy-Tickets mailing list