Skip to content

Commit 899bc74

Browse files
authored
Merge pull request #98 from MDAnalysis/prep-rel-060
finalize for 0.6.0
2 parents 3f7a17c + 2a4f667 commit 899bc74

File tree

4 files changed

+29
-6
lines changed

4 files changed

+29
-6
lines changed

.github/workflows/gh-ci.yaml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,13 @@ jobs:
2626
python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9]
2727
include:
2828
- os: windows-latest
29-
python-version: 3.7
29+
python-version: 2.7
30+
- os: windows-latest
31+
python-version: 3.9
32+
- os: macos-latest
33+
python-version: 2.7
34+
- os: macos-latest
35+
python-version: 3.9
3036

3137
steps:
3238
- uses: actions/checkout@v2
@@ -58,7 +64,7 @@ jobs:
5864
5965
- name: run unit tests
6066
run: |
61-
pytest -v --cov=gridData --cov-report=xml ./gridData/tests
67+
pytest -v --cov=gridData --cov-report=xml --color=yes ./gridData/tests
6268
6369
- name: codecov
6470
uses: codecov/codecov-action@v2

CHANGELOG

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,20 @@ The rules for this file:
1313
* accompany each entry with github issue/PR number (Issue #xyz)
1414

1515
------------------------------------------------------------------------------
16-
??/??/2019 eloyfelix, renehamburger1993, lilyminium, jvermaas
16+
10/10/2021 eloyfelix, renehamburger1993, lilyminium, jvermaas, xiki-tempula,
17+
IAlibay, orbeckst
1718

1819
* 0.6.0
1920

21+
Changes
22+
* macOS and Windows are also tested (min and max supported Python, #97)
23+
* switched CI to using GitHub actions (#86)
24+
2025
Enhancements
2126

22-
* Allow parsing/writing gzipped DX files
27+
* Allow parsing/writing gzipped DX files (PR #70, #99)
2328
* Update doc theme to use sphinx-rtd-theme (#80)
24-
* Delta of OpenDX writes 7 significant figures (#89)
29+
* Delta of OpenDX writes 7 significant figures (#88)
2530

2631
Fixes
2732

gridData/OpenDX.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,17 @@
174174

175175
import warnings
176176

177+
# Python 2/3 compatibility (see issue #99)
178+
# and https://bugs.python.org/issue30012
179+
import sys
180+
if sys.version_info >= (3, ):
181+
def _gzip_open(filename, mode="rt"):
182+
return gzip.open(filename, mode)
183+
else:
184+
def _gzip_open(filename, mode="rt"):
185+
return gzip.open(filename)
186+
del sys
187+
177188
class DXclass(object):
178189
"""'class' object as defined by OpenDX"""
179190
def __init__(self,classid):
@@ -707,7 +718,7 @@ def parse(self, DXfield):
707718
self.tokens = [] # token buffer
708719

709720
if self.filename.endswith('.gz'):
710-
with gzip.open(self.filename, 'rt') as self.dxfile:
721+
with _gzip_open(self.filename, 'rt') as self.dxfile:
711722
self.use_parser('general')
712723
else:
713724
with open(self.filename, 'r') as self.dxfile:

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
cmdclass=versioneer.get_cmdclass(),
1515
description="Reading and writing of data on regular grids in Python",
1616
long_description=long_description,
17+
long_description_content_type="text/x-rst",
1718
author="Oliver Beckstein",
1819
author_email="[email protected]",
1920
license="LGPLv3",

0 commit comments

Comments
 (0)