Skip to content

Commit ca240ca

Browse files
author
Jeff Whitaker
authored
Merge pull request #925 from Unidata/v1.5.1.2rel
prepare for 1.5.1.2 release
2 parents f7bd1d2 + a3c233e commit ca240ca

File tree

6 files changed

+24
-7
lines changed

6 files changed

+24
-7
lines changed

Changelog

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
since version 1.5.1.1
2-
==============================
1+
version 1.5.1.2 (tag v1.5.1.2rel)
2+
==================================
33
* fix another slicing bug introduced by the fix to issue #906 (issue #922).
44

55
version 1.5.1.1 (tag v1.5.1.1rel)

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@
1010
## News
1111
For details on the latest updates, see the [Changelog](https://github.com/Unidata/netcdf4-python/blob/master/Changelog).
1212

13+
05/06/2019: Version [1.5.1.2](https://pypi.python.org/pypi/netCDF4/1.5.1.2) released. Fixes another slicing
14+
slicing regression ([issue #922)](https://github.com/Unidata/netcdf4-python/issues/922)) introduced in the 1.5.1 release.
15+
1316
05/02/2019: Version [1.5.1.1](https://pypi.python.org/pypi/netCDF4/1.5.1.1) released. Fixes incorrect `__version__`
1417
module variable in 1.5.1 release, plus a slicing bug ([issue #919)](https://github.com/Unidata/netcdf4-python/issues/919)).
1518

docs/netCDF4/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1" />
55

66
<title>netCDF4 API documentation</title>
7-
<meta name="description" content="Version 1.5.1.1
7+
<meta name="description" content="Version 1.5.1.2
88
---------------
99
- - -
1010
@@ -1280,7 +1280,7 @@ <h1>Index</h1>
12801280

12811281
<header id="section-intro">
12821282
<h1 class="title"><span class="name">netCDF4</span> module</h1>
1283-
<h2>Version 1.5.1.1</h2>
1283+
<h2>Version 1.5.1.2</h2>
12841284
<hr />
12851285
<h1>Introduction</h1>
12861286
<p>netcdf4-python is a Python interface to the netCDF C library.</p>

netCDF4/_netCDF4.pyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
"""
2-
Version 1.5.1.1
2+
Version 1.5.1.2
33
---------------
44
- - -
55
@@ -1190,7 +1190,7 @@ except ImportError:
11901190
# python3: zip is already python2's itertools.izip
11911191
pass
11921192

1193-
__version__ = "1.5.1.1"
1193+
__version__ = "1.5.1.2"
11941194

11951195
# Initialize numpy
11961196
import posixpath

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,7 @@ def _populate_hdf5_info(dirstosearch, inc_dirs, libs, lib_dirs):
584584

585585
setup(name="netCDF4",
586586
cmdclass=cmdclass,
587-
version="1.5.1.1",
587+
version="1.5.1.2",
588588
long_description="netCDF version 4 has many features not found in earlier versions of the library, such as hierarchical groups, zlib compression, multiple unlimited dimensions, and new data types. It is implemented on top of HDF5. This module implements most of the new features, and can read and write netCDF files compatible with older versions of the library. The API is modelled after Scientific.IO.NetCDF, and should be familiar to users of that module.\n\nThis project is hosted on a `GitHub repository <https://github.com/Unidata/netcdf4-python>`_ where you may access the most up-to-date source.",
589589
author="Jeff Whitaker",
590590
author_email="[email protected]",

test/tst_slicing.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,5 +235,19 @@ def test_issue919(self):
235235
f['v1'][:] = arr
236236
assert_array_equal(f['v1'][:],np.broadcast_to(arr,f['v1'].shape))
237237

238+
def test_issue922(self):
239+
with Dataset(self.file,'w') as f:
240+
f.createDimension('d1',3)
241+
f.createDimension('d2',None)
242+
f.createVariable('v1',np.int,('d2','d1',))
243+
f['v1'][0] = np.arange(3,dtype=np.int)
244+
f['v1'][1:3] = np.arange(3,dtype=np.int)
245+
assert_array_equal(f['v1'][:], np.broadcast_to(np.arange(3),(3,3)))
246+
f.createVariable('v2',np.int,('d1','d2',))
247+
f['v2'][:,0] = np.arange(3,dtype=np.int)
248+
f['v2'][:,1:3] = np.arange(6,dtype=np.int).reshape(3,2)
249+
assert_array_equal(f['v2'][:,1:3],np.arange(6,dtype=np.int).reshape(3,2))
250+
assert_array_equal(f['v2'][:,0],np.arange(3,dtype=np.int))
251+
238252
if __name__ == '__main__':
239253
unittest.main()

0 commit comments

Comments
 (0)