reading netcdf broken in 0.11

Bug #1210244 reported by Julian Taylor
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-scipy (Ubuntu)
Fix Released
Undecided
Unassigned
Raring
Won't Fix
Undecided
Unassigned

Bug Description

in 0.11 reading netcdf files results in integer data in big endian format interpreted as native endian, this was fixed in 0.12:
https://github.com/scipy/scipy/pull/471

TESTCASE:
run:

from scipy.io import netcdf
import numpy as np

nc = netcdf.netcdf_file('foo.nc', 'w')
nc.createDimension('time', 10)
time = nc.createVariable('time', 'i', ('time',))
time[:] = np.arange(10)
time.units = 'days since 2008-01-01'
nc.close()

nc = netcdf.netcdf_file('foo.nc', 'r')
print nc.variables['time'].data

result
[ 0 16777216 33554432 50331648 67108864 83886080 100663296
 117440512 134217728 150994944]

expected result:
[0 1 2 3 4 5 6 7 8 9]

Regression potential:
low, the netcdf spec says the data must big endian and the patch only fixes this issue.

Julian Taylor (jtaylor)
Changed in python-scipy (Ubuntu):
status: New → Fix Released
description: updated
Revision history for this message
Rolf Leggewie (r0lf) wrote :

raring has seen the end of its life and is no longer receiving any updates. Marking the raring task for this ticket as "Won't Fix".

Changed in python-scipy (Ubuntu Raring):
status: New → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.