[Git][debian-gis-team/cftime][master] 4 commits: New upstream version 1.0.4.2

Bas Couwenberg gitlab at salsa.debian.org
Thu Oct 24 05:33:28 BST 2019



Bas Couwenberg pushed to branch master at Debian GIS Project / cftime


Commits:
71e924ac by Bas Couwenberg at 2019-10-24T04:27:27Z
New upstream version 1.0.4.2
- - - - -
eda8696e by Bas Couwenberg at 2019-10-24T04:27:27Z
Update upstream source from tag 'upstream/1.0.4.2'

Update to upstream version '1.0.4.2'
with Debian dir 4f1f4a37361ed299b4f43a9e2ab66308afdd17b0
- - - - -
e818a641 by Bas Couwenberg at 2019-10-24T04:27:40Z
New upstream release.

- - - - -
e02044ea by Bas Couwenberg at 2019-10-24T04:28:23Z
Set distribution to unstable.

- - - - -


5 changed files:

- README.md
- cftime/_cftime.pyx
- debian/changelog
- setup.py
- test/test_cftime.py


Changes:

=====================================
README.md
=====================================
@@ -10,6 +10,8 @@ Time-handling functionality from netcdf4-python
 [![Commits Status](https://img.shields.io/github/commits-since/UniData/cftime/latest.svg)](https://github.com/UniData/cftime/commits/master)
 
 ## News
+10/25/2019:  version 1.0.4.2 released (fix for [issue #126](https://github.com/Unidata/cftime/issues/126)).
+
 10/21/2019:  version 1.0.4 released.
 
 12/05/2018:  version 1.0.3.4 released (just to fix a problem with the source 


=====================================
cftime/_cftime.pyx
=====================================
@@ -43,7 +43,7 @@ cdef int[13] _spm_366day = [0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 33
 _rop_lookup = {Py_LT: '__gt__', Py_LE: '__ge__', Py_EQ: '__eq__',
                Py_GT: '__lt__', Py_GE: '__le__', Py_NE: '__ne__'}
 
-__version__ = '1.0.4'
+__version__ = '1.0.4.2'
 
 # Adapted from http://delete.me.uk/2005/03/iso8601.html
 # Note: This regex ensures that all ISO8601 timezone formats are accepted - but, due to legacy support for other timestrings, not all incorrect formats can be rejected.
@@ -183,7 +183,7 @@ def date2num(dates,units,calendar='standard'):
                 ismasked = True
             times = []
             for date in dates.flat:
-                if getattr(date, 'tzinfo') is not None:
+                if getattr(date, 'tzinfo',None) is not None:
                     date = date.replace(tzinfo=None) - date.utcoffset()
 
                 if ismasked and not date:


=====================================
debian/changelog
=====================================
@@ -1,3 +1,9 @@
+cftime (1.0.4.2-1) unstable; urgency=medium
+
+  * New upstream release.
+
+ -- Bas Couwenberg <sebastic at debian.org>  Thu, 24 Oct 2019 06:28:13 +0200
+
 cftime (1.0.4-1) unstable; urgency=medium
 
   * New upstream release.


=====================================
setup.py
=====================================
@@ -119,4 +119,5 @@ setup(
         'Programming Language :: Python :: 3.6',
         'Programming Language :: Python :: 3.7',
         'Topic :: Scientific/Engineering',
-        'License :: OSI Approved'])
+        'License :: OSI Approved :: GNU General Public License v3 (GPLv3)']
+    )


=====================================
test/test_cftime.py
=====================================
@@ -711,7 +711,10 @@ class cftimeTestCase(unittest.TestCase):
         assert(cftime.date2num(cftime.datetime(1, 12, 1, 0, 0, 0, 0, -1, 1), units='days since 01-01-01',calendar='noleap')  == 334.0)
         assert(cftime.date2num(cftime.num2date(1.0,units='days since 01-01-01',calendar='noleap'),units='days since 01-01-01',calendar='noleap') == 1.0)
         assert(cftime.date2num(cftime.DatetimeNoLeap(1980, 1, 1, 0, 0, 0, 0, 6, 1),'days since 1970-01-01','noleap') == 3650.0)
-
+        # issue #126
+        d = cftime.DatetimeProlepticGregorian(1, 1, 1)
+        assert(cftime.date2num(d, 'days since 0001-01-01',\
+            'proleptic_gregorian') == 0.0)
 
 class TestDate2index(unittest.TestCase):
 



View it on GitLab: https://salsa.debian.org/debian-gis-team/cftime/compare/c54abdecaebbb71c0d29fbfe8d9b70ec6a71be95...e02044ea179b9194981e0adca205aed63010fedf

-- 
View it on GitLab: https://salsa.debian.org/debian-gis-team/cftime/compare/c54abdecaebbb71c0d29fbfe8d9b70ec6a71be95...e02044ea179b9194981e0adca205aed63010fedf
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20191024/63653002/attachment-0001.html>


More information about the Pkg-grass-devel mailing list