[NumPy-Tickets] [NumPy] #1345: test_multiarray.TestIO.test_ascii segmentation fault with Python 2.7

NumPy Trac numpy-tickets@scipy....
Sat May 8 13:58:55 CDT 2010

#1345: test_multiarray.TestIO.test_ascii segmentation fault with Python 2.7
  Reporter:  bsouthey    |       Owner:  somebody
      Type:  defect      |      Status:  closed  
  Priority:  high        |   Milestone:  2.0.0   
 Component:  numpy.core  |     Version:  1.4.0rc1
Resolution:  fixed       |    Keywords:          

Comment(by pv):

 I don't think we should put it to 3kcompat, as it's rarely needed.

 The GIL is released by `fromfile`, which IMHO is the right thing to do,
 and the calls percolate down to dtype-specific conversion routines.

 Note that the functions called belong to the `PyOS_*` helper function
 family and one could wish these don't mess up with Python internals (since
 they don't really do anything with PyObjects), but that's unfortunately
 not true any more.

 The best and most efficient fix would probably be to borrow from somewhere
 some code converting strings to doubles (preferably supporting streaming,
 ie., a state machine) and back again, since it seems we can neither trust
 the facilities provided by the C library nor those from Python. Damnation.
 There's bound to be suitable BSD-compatible code somewhere, but I guess
 this is of low priority.

Ticket URL: <http://projects.scipy.org/numpy/ticket/1345#comment:10>
NumPy <http://projects.scipy.org/numpy>
My example project

More information about the NumPy-Tickets mailing list