Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-DateTime for openSUSE:Factory checked in at 2022-11-01 13:42:09
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-DateTime (Old)
and /work/SRC/openSUSE:Factory/.python-DateTime.new.2275 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-DateTime"
Tue Nov 1 13:42:09 2022 rev:4 rq:1032485 version:4.7
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-DateTime/python-DateTime.changes 2022-08-02 22:10:30.986001583 +0200
+++ /work/SRC/openSUSE:Factory/.python-DateTime.new.2275/python-DateTime.changes 2022-11-01 13:42:18.699814191 +0100
@@ -1,0 +2,12 @@
+Sat Oct 29 19:12:36 UTC 2022 - Yogalakshmi Arunachalam
+
+- Update to version 4.7:
+ * Fix rounding problem with DateTime addition beyond the year 2038 (#41)
+
+-------------------------------------------------------------------
+Tue Oct 11 23:16:05 UTC 2022 - Yogalakshmi Arunachalam
+
+- Update to version 4.6:
+ * Fix __format__ method for DateTime objects (#39)
+
+-------------------------------------------------------------------
Old:
----
DateTime-4.5.tar.gz
New:
----
DateTime-4.7.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-DateTime.spec ++++++
--- /var/tmp/diff_new_pack.AZbvVv/_old 2022-11-01 13:42:19.171816702 +0100
+++ /var/tmp/diff_new_pack.AZbvVv/_new 2022-11-01 13:42:19.179816744 +0100
@@ -18,7 +18,7 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-DateTime
-Version: 4.5
+Version: 4.7
Release: 0
Summary: Zope DateTime data type
License: ZPL-2.1
++++++ DateTime-4.5.tar.gz -> DateTime-4.7.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/DateTime-4.5/CHANGES.rst new/DateTime-4.7/CHANGES.rst
--- old/DateTime-4.5/CHANGES.rst 2022-07-04 08:31:17.000000000 +0200
+++ new/DateTime-4.7/CHANGES.rst 2022-09-14 08:29:54.000000000 +0200
@@ -1,6 +1,20 @@
Changelog
=========
+4.7 (2022-09-14)
+----------------
+
+- Fix rounding problem with `DateTime` addition beyond the year 2038
+ (`#41 https://github.com/zopefoundation/DateTime/issues/41`_)
+
+
+4.6 (2022-09-10)
+----------------
+
+- Fix ``__format__`` method for DateTime objects
+ (`#39 https://github.com/zopefoundation/DateTime/issues/39`_)
+
+
4.5 (2022-07-04)
----------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/DateTime-4.5/PKG-INFO new/DateTime-4.7/PKG-INFO
--- old/DateTime-4.5/PKG-INFO 2022-07-04 08:31:19.719161000 +0200
+++ new/DateTime-4.7/PKG-INFO 2022-09-14 08:29:56.309736000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 2.1
Name: DateTime
-Version: 4.5
+Version: 4.7
Summary: This package provides a DateTime data type, as known from Zope. Unless you need to communicate with Zope APIs, you're probably better off using Python's built-in datetime module.
Home-page: https://github.com/zopefoundation/DateTime
Author: Zope Foundation and Contributors
@@ -842,6 +842,20 @@
Changelog
=========
+4.7 (2022-09-14)
+----------------
+
+- Fix rounding problem with `DateTime` addition beyond the year 2038
+ (`#41 https://github.com/zopefoundation/DateTime/issues/41`_)
+
+
+4.6 (2022-09-10)
+----------------
+
+- Fix ``__format__`` method for DateTime objects
+ (`#39 https://github.com/zopefoundation/DateTime/issues/39`_)
+
+
4.5 (2022-07-04)
----------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/DateTime-4.5/setup.py new/DateTime-4.7/setup.py
--- old/DateTime-4.5/setup.py 2022-07-04 08:31:17.000000000 +0200
+++ new/DateTime-4.7/setup.py 2022-09-14 08:29:54.000000000 +0200
@@ -26,7 +26,7 @@
with open(os.path.join(here, 'CHANGES.rst')) as f:
CHANGES = f.read()
-version = '4.5'
+version = '4.7'
setup(
name='DateTime',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/DateTime-4.5/src/DateTime/DateTime.py new/DateTime-4.7/src/DateTime/DateTime.py
--- old/DateTime-4.5/src/DateTime/DateTime.py 2022-07-04 08:31:17.000000000 +0200
+++ new/DateTime-4.7/src/DateTime/DateTime.py 2022-09-14 08:29:54.000000000 +0200
@@ -864,7 +864,7 @@
# self._micros is the time since the epoch
# in long integer microseconds.
if microsecs is None:
- microsecs = long(math.floor(t * 1000000.0))
+ microsecs = long(round(t * 1000000.0))
self._micros = microsecs
def localZone(self, ltm=None):
@@ -1760,7 +1760,7 @@
x = _calcDependentSecond(tz, t)
yr, mo, dy, hr, mn, sc = _calcYMDHMS(x, ms)
return self.__class__(yr, mo, dy, hr, mn, sc, self._tz,
- t, d, s, None, self.timezoneNaive())
+ t, d, s, tmicros, self.timezoneNaive())
__radd__ = __add__
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/DateTime-4.5/src/DateTime/tests/test_datetime.py new/DateTime-4.7/src/DateTime/tests/test_datetime.py
--- old/DateTime-4.5/src/DateTime/tests/test_datetime.py 2022-07-04 08:31:17.000000000 +0200
+++ new/DateTime-4.7/src/DateTime/tests/test_datetime.py 2022-09-14 08:29:54.000000000 +0200
@@ -103,6 +103,16 @@
dt = DateTime()
self.assertEqual(str(dt + 0.10 + 3.14 + 6.76 - 10), str(dt),
dt)
+ # checks problem reported in
+ # https://github.com/zopefoundation/DateTime/issues/41
+ dt = DateTime(2038, 10, 7, 8, 52, 44.959840, "UTC")
+ self.assertEqual(str(dt + 0.10 + 3.14 + 6.76 - 10), str(dt),
+ dt)
+
+ def testConsistentSecondMicroRounding(self):
+ dt = DateTime(2038, 10, 7, 8, 52, 44.9598398, "UTC")
+ self.assertEqual(int(dt.second() * 1000000),
+ dt.micros() % 60000000)
def testConstructor3(self):
# Constructor from date/time string
@@ -686,10 +696,10 @@
@unittest.skipUnless(PY3K, 'format method is Python 3 only')
def test_format(self):
dt = DateTime(1968, 3, 10, 23, 45, 0, 'Europe/Vienna')
- fmt = '%-d.%-m.%Y %H:%M'
+ fmt = '%d.%m.%Y %H:%M'
result = dt.strftime(fmt)
unformatted_result = '1968/03/10 23:45:00 Europe/Vienna'
- self.assertEqual(result, '{:%-d.%-m.%Y %H:%M}'.format(dt))
+ self.assertEqual(result, '{:%d.%m.%Y %H:%M}'.format(dt))
self.assertEqual(unformatted_result, '{:}'.format(dt))
self.assertEqual(unformatted_result, '{}'.format(dt))
eval("self.assertEqual(result, f'{dt:{fmt}}')")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/DateTime-4.5/src/DateTime.egg-info/PKG-INFO new/DateTime-4.7/src/DateTime.egg-info/PKG-INFO
--- old/DateTime-4.5/src/DateTime.egg-info/PKG-INFO 2022-07-04 08:31:19.000000000 +0200
+++ new/DateTime-4.7/src/DateTime.egg-info/PKG-INFO 2022-09-14 08:29:55.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 2.1
Name: DateTime
-Version: 4.5
+Version: 4.7
Summary: This package provides a DateTime data type, as known from Zope. Unless you need to communicate with Zope APIs, you're probably better off using Python's built-in datetime module.
Home-page: https://github.com/zopefoundation/DateTime
Author: Zope Foundation and Contributors
@@ -842,6 +842,20 @@
Changelog
=========
+4.7 (2022-09-14)
+----------------
+
+- Fix rounding problem with `DateTime` addition beyond the year 2038
+ (`#41 https://github.com/zopefoundation/DateTime/issues/41`_)
+
+
+4.6 (2022-09-10)
+----------------
+
+- Fix ``__format__`` method for DateTime objects
+ (`#39 https://github.com/zopefoundation/DateTime/issues/39`_)
+
+
4.5 (2022-07-04)
----------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/DateTime-4.5/tox.ini new/DateTime-4.7/tox.ini
--- old/DateTime-4.5/tox.ini 2022-07-04 08:31:17.000000000 +0200
+++ new/DateTime-4.7/tox.ini 2022-09-14 08:29:54.000000000 +0200
@@ -17,16 +17,14 @@
[testenv]
skip_install = true
-# We need to pin setuptools < 60 until zc.buildout 3.x supports it.
deps =
- setuptools < 60
- zc.buildout==3.0.0rc2
+ zc.buildout >= 3.0.0rc3
wheel > 0.37
commands_pre =
py27,py35: {envbindir}/buildout -nc {toxinidir}/buildout4.cfg buildout:directory={envdir} buildout:develop={toxinidir} install test
!py27-!py35: {envbindir}/buildout -nc {toxinidir}/buildout.cfg buildout:directory={envdir} buildout:develop={toxinidir} install test
commands =
- {envbindir}/test {posargs:-cv}
+ {envdir}/bin/test {posargs:-cv}
[testenv:lint]
basepython = python3
@@ -69,7 +67,7 @@
coverage-python-version
commands =
mkdir -p {toxinidir}/parts/htmlcov
- coverage run {envbindir}/test {posargs:-cv}
+ coverage run {envdir}/bin/test {posargs:-cv}
coverage html
coverage report -m --fail-under=88